• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# Controls.SelectionChangedEventArgs类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中Windows.UI.Xaml.Controls.SelectionChangedEventArgs的典型用法代码示例。如果您正苦于以下问题:C# SelectionChangedEventArgs类的具体用法?C# SelectionChangedEventArgs怎么用?C# SelectionChangedEventArgs使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



SelectionChangedEventArgs类属于Windows.UI.Xaml.Controls命名空间,在下文中一共展示了SelectionChangedEventArgs类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: cmbLanguage_SelectionChanged

 private void cmbLanguage_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     //set current Language
     string selectedValue = (string)cmbLanguage.SelectedValue;
     if (selectedValue == "中文(中华人民共和国)")
     {
         if (Windows.Globalization.ApplicationLanguages.PrimaryLanguageOverride != "zh-Hans-CN")
         {
             this.currentLanguage = "zh-Hans-CN";
             this.txtLanguageTip.Visibility = Visibility.Visible;
             this.btnClose.Visibility = Visibility.Visible;
         }
         else
         {
             this.txtLanguageTip.Visibility = Visibility.Collapsed;
             this.btnClose.Visibility = Visibility.Collapsed;
         }
     }
     else
     {
         if (Windows.Globalization.ApplicationLanguages.PrimaryLanguageOverride != "en-US")
         {
             this.currentLanguage = "en-US";
             this.txtLanguageTip.Visibility = Visibility.Visible;
             this.btnClose.Visibility = Visibility.Visible;
         }
         else
         {
             this.txtLanguageTip.Visibility = Visibility.Collapsed;
             this.btnClose.Visibility = Visibility.Collapsed;
         }
     }
 }
开发者ID:XPOWERLM,项目名称:More-Personal-Computing,代码行数:33,代码来源:Setting.xaml.cs


示例2: listBox_SelectionChanged

        private async void listBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
             string item = listBox.SelectedItem.ToString();
            if  (item.Equals("Do I have to register to avail the services?"))
            {
               await new MessageDialog("Yes, you must register to avail our services. This would help you to store your information with us and you do not have to enter your details everytime you use this app.").ShowAsync();

            }

            else if (item.Equals("Are there any registration charges for creating an account?"))
            {
                await new MessageDialog("No, there are no registration charges applicable for creating an account with us. It is absolutely free of cost.").ShowAsync();
            }
            else if (item.Equals("What should I do if I have trouble with logging in?"))

            {
                await new MessageDialog("Follow these instructions if you face an issue logging in: Check your login details. Make sure your username and password should match with the signup credentials. If you have forgotten your password, reset your password using the ‘Forgot your Password’ link on the sign-in page. If you are still unable to access your account, please contact us. We will resolve the issue at the earliest.").ShowAsync();
            }
            else if (item.Equals("Should I be concerned with the privacy of my personal details I have shared with the app?"))
            {
                await new MessageDialog("Do not worry! We are absolutely committed to safeguarding your personal information. The personal information collected is to validate your identity, as well as to provide us with a way to get in touch with you if the need should arise. We follow strict security procedures in the storage and disclosure of information which you have given us, to prevent unauthorised access. We do not pass on, trade or sell your personal information to anyone.").ShowAsync();
            }
            else if (item.Equals("What if I have additional questions?"))
            {
               await new MessageDialog("If you have any additional questions, comments or other general customer service inquiries, please submit your query using contact us link. We will resolve the issue at the earliest.").ShowAsync();
            }

            else
            {

            }
        }
开发者ID:rohit101293,项目名称:RoadPlex,代码行数:32,代码来源:Faq.xaml.cs


示例3: Filter_SelectionChanged

        /// <summary>
        /// Invoked when a filter is selected using the ComboBox in snapped view state.
        /// </summary>
        /// <param name="sender">The ComboBox instance.</param>
        /// <param name="e">Event data describing how the selected filter was changed.</param>
        void Filter_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            // Determine what filter was selected
            var selectedFilter = e.AddedItems.FirstOrDefault() as Filter;
            if (selectedFilter != null)
            {
                // Mirror the results into the corresponding Filter object to allow the
                // RadioButton representation used when not snapped to reflect the change
                selectedFilter.Active = true;

                // TODO: Respond to the change in active filter by setting this.DefaultViewModel["Results"]
                //       to a collection of items with bindable Image, Title, Subtitle, and Description properties

                // Ensure results are found
                object results;
                ICollection resultsCollection;
                if (this.DefaultViewModel.TryGetValue("Results", out results) &&
                    (resultsCollection = results as ICollection) != null &&
                    resultsCollection.Count != 0)
                {
                    VisualStateManager.GoToState(this, "ResultsFound", true);
                    return;
                }
            }

            // Display informational text when there are no search results.
            VisualStateManager.GoToState(this, "NoResultsFound", true);
        }
开发者ID:soreygarcia,项目名称:Sugges.me,代码行数:33,代码来源:SearchResultsPage.xaml.cs


示例4: Filter_SelectionChanged

        /// <summary>
        /// Invoked when a filter is selected using the ComboBox in snapped view state.
        /// </summary>
        /// <param name="sender">The ComboBox instance.</param>
        /// <param name="e">Event data describing how the selected filter was changed.</param>
        async void Filter_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            // Determine what filter was selected
            var selectedFilter = e.AddedItems.FirstOrDefault() as Filter;
            if (selectedFilter != null)
            {
                // Mirror the results into the corresponding Filter object to allow the
                // RadioButton representation used when not snapped to reflect the change
                selectedFilter.Active = true;

                ElementsDataSource model = new ElementsDataSource();
                await model.LoadElements();
                var elements = model.Elements.Where(t => t.Name.ToLower().Contains(((string)this.DefaultViewModel["QueryText"]).ToLower())).AsEnumerable();
                this.DefaultViewModel["Results"] = elements;

                selectedFilter.Count = elements.Count();

                // Ensure results are found
                object results;
                if (this.DefaultViewModel.TryGetValue("Results", out results) && elements.Count() > 0)
                {
                    VisualStateManager.GoToState(this, "ResultsFound", true);
                    return;
                }
            }

            // Display informational text when there are no search results.
            VisualStateManager.GoToState(this, "NoResultsFound", true);
        }
开发者ID:reyx,项目名称:Reyx.Win8.PeriodicTable,代码行数:34,代码来源:SearchResultsPage.xaml.cs


示例5: itemListView_SelectionChanged

 void itemListView_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (this.UsingLogicalPageNavigation())
     {
         this.navigationHelper.GoBackCommand.RaiseCanExecuteChanged();
     }
 }
开发者ID:xxy1991,项目名称:cozy,代码行数:7,代码来源:SplitPage1.xaml.cs


示例6: menuItems_SelectionChanged

 private void menuItems_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if(Home.IsSelected)
             Frame.Navigate(typeof(MainPage));
      else
         Frame.Navigate(typeof(MainPage));
 }
开发者ID:nhansky,项目名称:TripPlanner,代码行数:7,代码来源:MainPage.xaml.cs


示例7: NavMenu_SelectionChanged

 private void NavMenu_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     var listBox = (ListBox)sender;
     if (listBox.SelectedIndex == -1) return;
     NavStrip.IsPaneOpen = false;
     ContentFrame.Navigate(((NavItem)listBox.SelectedItem).Page);
 }
开发者ID:hyprsoftcorp,项目名称:WindowsIoTCoreDashboard,代码行数:7,代码来源:MainPage.xaml.cs


示例8: listBox_SelectionChanged

 private void listBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     var selectedId = (sender as ListBox).SelectedIndex;
     Problems clickedProblem = (Problems)listofitems[selectedId];
     var navCont = new CodeEditorContext(clickedProblem, "Problems");
     Frame.Navigate(typeof(CodeEditor), navCont);
 }
开发者ID:sakshamsharma,项目名称:CodeInn,代码行数:7,代码来源:ProblemViewer.xaml.cs


示例9: gvMain_SelectionChanged

        private async void gvMain_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            if (e != null && e.AddedItems != null && e.AddedItems.Count > 0)
            {
                var item  = (Photo)e.AddedItems[0];

                //DOWNLOAD ACTUAL IMAGE INTO PICTURES LIBRARY
                await DownloadService.Current.Downloader("1", item.MediumUrl, string.Empty, item.PhotoId + "_" + item.Secret, 2, storageFolder: "ModernCSApp");


                //UPDATE D2D BACKGROUND WITH DOWNLOADED IMAGE
                var br = RenderingService.BackgroundRenderer;
                string[] partsUrl = item.MediumUrl.Split(".".ToCharArray());
                br.ChangeBackground("ModernCSApp\\" + item.PhotoId + "_" + item.Secret + "." + partsUrl[partsUrl.Length - 1], "PicturesLibrary");


                ////REQUEST TO MINIMIZE THIS LIST IN ITS PARENT
                //if (ChangeViewState != null)
                //{
                //    this._currentViewState = "Minimized";
                //    grdTitle.Opacity = 0.5;
                //    ChangeViewState("Minimized", EventArgs.Empty);
                //}

                //TELL PARENT PICTURE HAS CHANGED
                if (PictureChanged != null)
                {
                    PictureChanged(Serialize(item), EventArgs.Empty);
                }

                ////DISABLE THE LIST TILL ITS NORMAL/MAXIMIZED
                //gvMain.IsEnabled = false;

            }
        }
开发者ID:rolandsmeenk,项目名称:ModernApps,代码行数:35,代码来源:PictureViews.xaml.cs


示例10: cboxDebug_SelectionChanged

        void cboxDebug_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            //graph.VertexList.Values.ForEach(a => a.VertexConnectionPointsList.ForEach(b => b.Hide()));
            graph.ClearLayout();
            graph.LogicCore.Graph.Clear();
            graph.LogicCore.EnableParallelEdges = false;
            graph.LogicCore.ParallelEdgeDistance = 25;
            graph.LogicCore.EdgeCurvingEnabled = false;

            graph.SetVerticesDrag(true, true);
            graph.SetVerticesMathShape(VertexShape.Circle);
            graph.ShowAllVerticesLabels(false);
            graph.ShowAllEdgesLabels(false);
            graph.AlignAllEdgesLabels(false);

            switch ((DebugItems)cboxDebug.SelectedItem)
            {
                case DebugItems.General:
                    DebugGeneral();
                    break;
                case DebugItems.EdgeLabels:
                    DebugEdgeLabels();
                    break;
                case DebugItems.VCP:
                    DebugVCP();
                    break;
            }

        }
开发者ID:aliaspilote,项目名称:TX52,代码行数:29,代码来源:MainPageDebug.xaml.cs


示例11: ListMenuItems_SelectionChanged

 private void ListMenuItems_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     ListView a = sender as ListView;
     string b = a.SelectedItem as string;
     if (b[0] == 'C')
     {
         Frame.Navigate(typeof(Compare));
     }
     if (b[0] == 'L')
     {
         Frame.Navigate(typeof(ResultPage));
     }
     if (b[0] == 'e')
     {
         Frame.Navigate(typeof(ex_Result));
     }
     if (b[0] == 'M')
     {
         Frame.Navigate(typeof(Aukat));
     }
     if (b[0] == 'A')
     {
         Frame.Navigate(typeof(About));
     }
     if (b[0] == 'F')
     {
         Frame.Navigate(typeof(Feedback));
     }
 }  
开发者ID:AkshayGupta94,项目名称:ProjectAukatFinal,代码行数:29,代码来源:About.xaml.cs


示例12: IntervalBox_SelectionChanged

        private void IntervalBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            var selectedItem = (ComboBoxItem)e.AddedItems.First();
            uint timeInterval = 0;

            switch (selectedItem.Name)
            {
                case "IntervalNever":
                    timeInterval = 0;
                    break;
                case "Interval30":
                    timeInterval = 30;
                    break;
                case "Interval60":
                    timeInterval = 60;
                    break;
                case "Interval90":
                    timeInterval = 90;
                    break;
                case "Interval2h":
                    timeInterval = 120;
                    break;
                case "Interval6h":
                    timeInterval = 360;
                    break;
                case "IntervalOnce":
                    timeInterval = 720;
                    break;
            }

            BackgroundHelper.RegisterBackgroundTask(timeInterval);
            ApplicationData.Current.LocalSettings.Values["currentInterval"] = timeInterval;
        }
开发者ID:n01d,项目名称:StackOverflowNotifier,代码行数:33,代码来源:SettingsPage.xaml.cs


示例13: Selector_OnSelectionChanged

 private void Selector_OnSelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (e.AddedItems.Count == 1)
     {
         HomeViewModel.SwitchRoomCommand.Execute(e.AddedItems[0]);
     }
 }
开发者ID:Redth,项目名称:JabbRIsMobile,代码行数:7,代码来源:HomeView.xaml.cs


示例14: flipView_SelectionChanged

        private void flipView_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            int prevMinIndex = minIndex;
            int prevMaxIndex = maxIndex;
            minIndex = Math.Max(0, flipView.SelectedIndex - 30);
            maxIndex = Math.Min(flipView.Items.Count - 1, flipView.SelectedIndex + 30);

            if (maxIndex > prevMaxIndex)
            {
                AddImageToMemory(maxIndex);
            }
            else if (maxIndex < prevMinIndex)
            {
                RemoveImageFromMemory(maxIndex);
            }
            if (minIndex < prevMinIndex)
            {
                AddImageToMemory(minIndex);
            }
            else if (minIndex > prevMinIndex)
            {
                RemoveImageFromMemory(minIndex);
            }

            dateText.Text = ((Photo)(flipView.SelectedItem)).Date.ToString();
        }
开发者ID:jonfortescue,项目名称:PhotoOrganizer,代码行数:26,代码来源:CollectionViewer.xaml.cs


示例15: ComboSize_SelectionChanged

 private void ComboSize_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     switch (ComboSize.SelectedIndex)
     {
         case 0:
             settings.m_uXnum = 10;
             settings.m_uYnum = 10;
             settings.m_uMineNum = 8;
             break;
         case 1:
             settings.m_uXnum = 16;
             settings.m_uYnum = 16;
             settings.m_uMineNum = 40;
             break;
         case 2:
             settings.m_uXnum = 20;
             settings.m_uYnum = 20;
             settings.m_uMineNum = 80;
             break;
         case 3:
             settings.m_uXnum = 0;
             settings.m_uYnum = 0;
             settings.m_uMineNum = 0;
             break;
     }
 }
开发者ID:lantian2012,项目名称:MineSweeper,代码行数:26,代码来源:SimpleSettingsNarrow.xaml.cs


示例16: AnimationComboBox_SelectionChanged

        private void AnimationComboBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            if (this.AnimationCombo == null)
                return;

            fadeTile.AnimationType = (ImageTileAnimationTypes)Enum.Parse(typeof(ImageTileAnimationTypes), (string)(this.AnimationCombo.SelectedItem as ComboBoxItem).Content);
        }
开发者ID:selaromdotnet,项目名称:Coding4FunToolkit,代码行数:7,代码来源:ImageTiles.xaml.cs


示例17: FlipView_SelectionChanged

 private void FlipView_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if ((sender as FlipView).SelectedItem != null)
     {
         this.eventTitle.Text = ((sender as FlipView).SelectedItem as EventItemViewModel).Title;
     }
 }
开发者ID:Rbeuque74,项目名称:w8_cinefips,代码行数:7,代码来源:EventsDetails.xaml.cs


示例18: Characteristics_SelectionChanged

 private void Characteristics_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (e.AddedItems.Count != 0)
     {
         viewmodel.GetDescriptors("");
     }
 }
开发者ID:EarnieGC,项目名称:AppAcceleratorKit,代码行数:7,代码来源:ItemsPage.xaml.cs


示例19: lbPictures_SelectionChanged

        private async void lbPictures_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            if (e != null &&  e.AddedItems.Count > 0)
            {
                var ili = e.AddedItems[0] as ImageListItem;

                ImageUri = $"x-ext://{ili.AppExtensionId}/{ili.File}";

                ImageChanged?.Invoke(sender, new ImagePickerEventArgs() {
                    Text = ImageUri,
                    AppExtensionId = ili.AppExtensionId,
                    File = ili.File });

                

                //set imagesource
                var el = ExtensionsService.Instance.FindExtensionLiteInstance(ili.AppExtensionId);
                var packageDirectory = el.AppExtension.Package.InstalledLocation;
                var publicDirectory = await packageDirectory.GetFolderAsync("public");
                var ImageFile = await publicDirectory.GetFileAsync(ili.File);
                var bitmapImage = new BitmapImage();
                using (var stream = await ImageFile.OpenReadAsync())
                {
                    await bitmapImage.SetSourceAsync(stream);
                }
                ImageSource = bitmapImage;
            }
        }
开发者ID:liquidboy,项目名称:X,代码行数:28,代码来源:ImagePicker.xaml.cs


示例20: Services_SelectionChanged

 private void Services_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (e.AddedItems.Count != 0)
     {
         viewmodel.GetSelectedServicesCharacteristics("");
     }
 }
开发者ID:EarnieGC,项目名称:AppAcceleratorKit,代码行数:7,代码来源:ItemsPage.xaml.cs



注:本文中的Windows.UI.Xaml.Controls.SelectionChangedEventArgs类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# Controls.StackPanel类代码示例发布时间:2022-05-26
下一篇:
C# Controls.ScrollViewerViewChangedEventArgs类代码示例发布时间:2022-05-26
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap