Ejemplo n.º 1
0
        void OnItemSelected(object sender, SelectedItemChangedEventArgs e)
        {
            ChatRoom chatRoom         = e.SelectedItem as ChatRoom;
            var      chatRoomItemPage = new ChatRoomItemPage(chatRoom);

            Navigation.PopAsync(true);
            Navigation.PushAsync(chatRoomItemPage);
        }
        void OnItemSelected(object sender, SelectedItemChangedEventArgs e)
        {
            ChatRoom chatRoom = e.SelectedItem as ChatRoom;

            if ((int)Enumerations.ChatRoomType.Public == chatRoom.Type)
            {
                var chatRoomItemPage = new ChatRoomItemPage(chatRoom);
                Navigation.PopAsync(true);
                Navigation.PushAsync(chatRoomItemPage);
            }
            else
            {
                var page = new ModalPrivateChatRoomLoginPage(chatRoom, Navigation);
                Navigation.PushPopupAsync(page);
            }
        }
Ejemplo n.º 3
0
        private void OnClickedConfirm(object sender, EventArgs e)
        {
            if (etyPassword.Text == mChatRoom.Password)
            {
                var chatRoomItemPage = new ChatRoomItemPage(mChatRoom);
                PopupNavigation.PopAsync();
                mNavigation.PushAsync(chatRoomItemPage);
            }
            else
            {
                ToastConfig tc = new ToastConfig(AppResources.PasswordIncorrect)
                                 .SetDuration(TimeSpan.FromSeconds(3));

                UserDialogs.Instance.Toast(tc);
            }
        }