当前位置: 首页>>代码示例>>C#>>正文


C# IFavorite.GetToolTipText方法代码示例

本文整理汇总了C#中IFavorite.GetToolTipText方法的典型用法代码示例。如果您正苦于以下问题:C# IFavorite.GetToolTipText方法的具体用法?C# IFavorite.GetToolTipText怎么用?C# IFavorite.GetToolTipText使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在IFavorite的用法示例。


在下文中一共展示了IFavorite.GetToolTipText方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: AssertCopy

        private void AssertCopy(IFavorite copy)
        {
            int stored = this.CheckDatabase.Favorites.Count();
            Assert.AreEqual(2, stored, "Favorites count doesn't match after copy added to the persistence");
            IFavorite secondary = this.SecondaryFavorites.ToList()[1];
            Assert.AreEqual(secondary.ServerName, FAVORITE_SERVERNAME2, "Values not updated properly");

            // next method loads details of not loaded favorite from database, it shouldn't fail, even if it is a copy
            string toolTip = copy.GetToolTipText();
            Assert.IsFalse(string.IsNullOrEmpty(toolTip), "ToolTip wasn't resolved for copy of favorite");
        }
开发者ID:oo00spy00oo,项目名称:SharedTerminals,代码行数:11,代码来源:FavoriteCopiesTest.cs

示例2: UpdateByFavorite

        internal void UpdateByFavorite(IFavorite favorite)
        {
            this.Name = favorite.Name;
            this.Text = favorite.Name;
            this.Favorite = favorite;
            this.Tag = favorite; // temporary solution, for backward compatibility only

            this.ImageKey = FavoriteIcons.GetTreeviewImageListKey(favorite.Protocol);
            this.SelectedImageKey = this.ImageKey;
            // possible performance hit on SQL persistence, when loading details for each created favorite and also in menu loader
            this.ToolTipText = favorite.GetToolTipText();
        }
开发者ID:oo00spy00oo,项目名称:SharedTerminals,代码行数:12,代码来源:FavoriteTreeNode.cs

示例3: CreateFavoriteButton

 private ToolStripButton CreateFavoriteButton(IFavorite favorite)
 {
     Image buttonImage = favorite.ToolBarIconImage;
     ToolStripButton favoriteBtn = new ToolStripButton(favorite.Name, buttonImage, this.serverToolStripMenuItemClick);
     favoriteBtn.ToolTipText = favorite.GetToolTipText();
     favoriteBtn.Tag = favorite;
     favoriteBtn.Overflow = ToolStripItemOverflow.AsNeeded;
     return favoriteBtn;
 }
开发者ID:oo00spy00oo,项目名称:SharedTerminals,代码行数:9,代码来源:FavoritesMenuLoader.cs

示例4: CreateFavoriteMenuItem

 private static ToolStripMenuItem CreateFavoriteMenuItem(IFavorite favorite)
 {
     ToolStripMenuItem item = new ToolStripMenuItem(favorite.Name);
     item.Tag = FAVORITE;
     item.Image = favorite.ToolBarIconImage;
     item.ToolTipText = favorite.GetToolTipText();
     return item;
 }
开发者ID:oo00spy00oo,项目名称:SharedTerminals,代码行数:8,代码来源:FavoritesMenuLoader.cs

示例5: FavoriteToListViewItem

 private static ListViewItem FavoriteToListViewItem(IFavorite favorite)
 {
     var item = new ListViewItem();
     item.Tag = favorite;
     item.Text = favorite.Name;
     item.ToolTipText = favorite.GetToolTipText();
     item.ImageKey = FavoriteIcons.GetTreeviewImageListKey(favorite.Protocol);
     return item;
 }
开发者ID:oo00spy00oo,项目名称:SharedTerminals,代码行数:9,代码来源:SearchResultsPanel.cs


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