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

C# Visibility类代码示例

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

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



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

示例1: MessageViewModel

        public MessageViewModel(int uid, int mid, string body, string dateTime, bool isOut, bool isSent, bool isRead,
            bool isDeleted, BitmapImage accountPhoto, ObservableCollection<AttachmentViewModel> attachments)
        {
            _isSelected = false;
            Mid = mid;
            Uid = uid;

            _body = body;
            _dateTime = dateTime;
            _photo = accountPhoto;

            _SetUserData(uid);

            _isOut = isOut;
            _isRead = isRead;
            _isDeleted = isDeleted;

            if (isSent && isOut && !isRead)
                _notReadVisibility = Visibility.Visible;
            else
                _notReadVisibility = Visibility.Collapsed;

            _isSent = isSent;

            _attachments = attachments;
        }
开发者ID:optiklab,项目名称:VKMessanger,代码行数:26,代码来源:MessageViewModel.cs


示例2: NewModel

        public static ServiceModel NewModel(Type compositeType,
                                            Visibility visibility,
                                            MetaInfo metaInfo,
                                            IEnumerable<Type> assemblyConcerns,
                                            IEnumerable<Type> sideEffects,
                                            IList<Type> mixins,
                                            String moduleName,
                                            String identity,
                                            bool instantiateOnStartup)
        {
            PropertyDeclarations propertyDeclarations = new MetaInfoDeclaration();
            var constraintsModel = new ConstraintsModel(compositeType);
            bool immutable = metaInfo.Get<ImmutableAttribute>() != null;
            var propertiesModel = new ServicePropertiesModel(constraintsModel, propertyDeclarations, immutable);
            var stateModel = new ServiceStateModel(propertiesModel);
            var mixinsModel = new MixinsModel(compositeType, mixins);

            var concerns = new List<ConcernDeclaration>();
            ConcernsDeclaration.ConcernDeclarations(assemblyConcerns, concerns);
            ConcernsDeclaration.ConcernDeclarations(compositeType, concerns);
            var concernsModel = new ConcernsDeclaration(concerns);
            var sideEffectsModel = new SideEffectsDeclaration(compositeType, sideEffects);
            var compositeMethodsModel = new CompositeMethodsModel(compositeType, constraintsModel, concernsModel, sideEffectsModel, mixinsModel);
            stateModel.AddStateFor(compositeMethodsModel.Properties, compositeType);

            return new ServiceModel(
                    compositeType, visibility, metaInfo, mixinsModel, stateModel, compositeMethodsModel, moduleName, identity, instantiateOnStartup);
        }
开发者ID:attila3453,项目名称:alsing,代码行数:28,代码来源:ServiceModel.cs


示例3: FileUploadSettingsPage

        public FileUploadSettingsPage()
        {
            InitializeComponent();
            this.DataContext = YellowstonePathology.YpiConnect.Contract.Identity.ApplicationIdentity.Instance.WebServiceAccount;
            if (YellowstonePathology.YpiConnect.Contract.Identity.ApplicationIdentity.Instance.WebServiceAccount.EnableFileUpload)
            {
                this.m_CommentVisibility = System.Windows.Visibility.Collapsed;
                this.CheckBoxEnabled.IsChecked = true;
                if (string.IsNullOrEmpty(YellowstonePathology.YpiConnect.Contract.Identity.ApplicationIdentity.Instance.WebServiceAccount.LocalFileUploadDirectory) == true)
                {
                    this.LocalFileUploadDirectory = @"C:\Program Files\Yellowstone Pathology Institute\Client Services\Reports";
                }
                else
                {
                    this.LocalFileUploadDirectory = YellowstonePathology.YpiConnect.Contract.Identity.ApplicationIdentity.Instance.WebServiceAccount.LocalFileUploadDirectory;
                }
            }
            else
            {
                this.m_CommentVisibility = System.Windows.Visibility.Visible;
                this.CheckBoxEnabled.IsChecked = false;
            }

            this.DataContext = this;

            MainWindow mainWindow = (MainWindow)System.Windows.Application.Current.MainWindow;
            this.HyperlinkSignOut.Click += new RoutedEventHandler(mainWindow.ButtonSignOut_Click);
            Loaded += new RoutedEventHandler(FileUploadSettingsPage_Loaded);
        }
开发者ID:WilliamCopland,项目名称:YPILIS,代码行数:29,代码来源:FileUploadSettingsPage.xaml.cs


示例4: DataGridColumn

 /// <summary>
 /// Initializes a new instance of the <see cref="T:System.Windows.Controls.DataGridColumn" /> class.
 /// </summary>
 protected internal DataGridColumn()
 {
     this._visibility = Visibility.Visible;
     this._displayIndexWithFiller = -1;
     this.IsInitialDesiredWidthDetermined = false;
     this.InheritsWidth = true;
 }
开发者ID:kvervo,项目名称:HorizontalLoopingSelector,代码行数:10,代码来源:DataGridColumn.cs


示例5: New

        /// <summary>
        /// Creates an instance of <see cref="IBoilerplateContext"/>
        /// </summary>
        /// <param name="identity">The current identity being used (rights and roles contract requirements/restrictions will apply to this identity)</param>
        /// <param name="accessProvider">An access provider for specific types (available through IBoilerplateContext.Open&lt;T&gt;())</param>
        /// <param name="permissionsProvider">The provider that will be used for all permissions verification attempts</param>
        /// <param name="visibility">The visibility level that this context has. This will affect operations that rely on visibility (e.g. logging).</param>
        /// <returns>An instance of <see cref="IBoilerplateContext"/></returns>
        public static IBoilerplateContext New(IIdentity identity = null, 
                                              ITypeAccessProvider accessProvider = null, 
                                              IPermissionsProvider permissionsProvider = null,
                                              Visibility visibility = Visibility.None)
        {   
            var actualIdentity = identity ?? Identity.Default;
            var actualTypeAccessProvider = accessProvider ?? TypeAccessProvider.Empty;
            var actualPermissionsProvider = permissionsProvider ?? PermissionsProvider.Default;

            var functionGenerator = new FunctionGenerator();

            //Core providers
            var translationProvider = new TranslationProvider(functionGenerator);
            var validationProvider = new ValidationProvider(functionGenerator);
            var logProvider = new LogProvider(functionGenerator, visibility);

            //Set up error handling
            var tryCatchProvider = new TryCatchBlockProvider(functionGenerator);
            var exceptionHandlerProvider = new ExceptionHandlerProvider(logProvider);
            var errorContext = new ImmutableErrorContext(logProvider, tryCatchProvider, exceptionHandlerProvider);

            var bundle = new ContextBundle(permissionsProvider: actualPermissionsProvider,
                                           errorContext: errorContext,
                                           translationProvider: translationProvider,
                                           accessProvider: actualTypeAccessProvider,
                                           validationProvider: validationProvider,
                                           logProvider: logProvider,
                                           visibility: visibility);

            return new InitialBoilerplateContext<ContractContext>(bundle, actualIdentity);
        }
开发者ID:Norhaven,项目名称:FluentBoilerplate,代码行数:39,代码来源:Boilerplate.cs


示例6: CreateEdgeControl

        public EdgeControl CreateEdgeControl(VertexControl source, VertexControl target, object edge, bool showLabels = false, bool showArrows = true, Visibility visibility = Visibility.Visible)
        {
            var edgectrl = new EdgeControl(source, target, edge, showLabels, showArrows) { Visibility = visibility, RootArea = FactoryRootArea};

            return edgectrl;

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


示例7: PropertyBase

 protected PropertyBase(PropertyEditor owner)
 {
     Owner = owner;
     
     isEnabled = true;
     isVisible = Visibility.Visible;
 }
开发者ID:hpbaotho,项目名称:sambapos,代码行数:7,代码来源:PropertyBase.cs


示例8: ProviderDistributionPage

        //private bool m_Closing;
        public ProviderDistributionPage(string reportNo, 
            YellowstonePathology.Business.Test.AccessionOrder accessionOrder,
            YellowstonePathology.UI.Navigation.PageNavigator pageNavigator,
            Visibility nextButtonVisibility,
            Visibility closeButtonVisibility,
            Visibility backButtonVisibility)
        {
            this.m_PageNavigator = pageNavigator;

            this.m_AccessionOrder = accessionOrder;
            this.m_PanelSetOrder = accessionOrder.PanelSetOrderCollection.GetPanelSetOrder(reportNo);

            this.m_NextButtonVisibility = nextButtonVisibility;
            this.m_CloseButtonVisibility = closeButtonVisibility;
            this.m_BackButtonVisibility = backButtonVisibility;

            this.m_SystemUserCollection = YellowstonePathology.Business.User.SystemUserCollectionInstance.Instance.SystemUserCollection;

            this.m_ClientPhysicianNotSetAuditCollection = new Business.Audit.Model.AuditCollection();
            this.m_ClientPhysicianNotSetAuditCollection.Add(new YellowstonePathology.Business.Audit.Model.ClientNotSetAudit(this.m_AccessionOrder));
            this.m_ClientPhysicianNotSetAuditCollection.Add(new YellowstonePathology.Business.Audit.Model.PhysicianNotSetAudit(this.m_AccessionOrder));

            InitializeComponent();

            DataContext = this;

            this.Loaded += new RoutedEventHandler(ProviderDetailPage_Loaded);
            Close += ProviderDistributionPage_Close;
        }
开发者ID:WilliamCopland,项目名称:YPILIS,代码行数:30,代码来源:ProviderDistributionPage.xaml.cs


示例9: ReviewClientOrderPage

        public ReviewClientOrderPage(YellowstonePathology.Business.Rules.Surgical.PatientRecentAccessions patientRecentAccessions,
			YellowstonePathology.Business.ClientOrder.Model.ClientOrder clientOrder,
			UI.Navigation.PageNavigator pageNavigator)
        {
            this.m_PatientRecentAccessions = patientRecentAccessions;
            this.m_ClientOrder = clientOrder;
            this.m_PageNavigator = pageNavigator;

            InitializeComponent();

            this.DataContext = this;

            if (this.m_ClientOrder.Accessioned == true)
            {
                this.m_CloseButtonVisibility = System.Windows.Visibility.Collapsed;
                this.m_NextButtonVisibility = System.Windows.Visibility.Visible;
            }
            else
            {
                this.m_CloseButtonVisibility = System.Windows.Visibility.Visible;
                this.m_NextButtonVisibility = System.Windows.Visibility.Collapsed;
            }

            this.Loaded += new RoutedEventHandler(ReviewClientOrderPage_Loaded);
        }
开发者ID:ericramses,项目名称:YPILIS,代码行数:25,代码来源:ReviewClientOrderPage.xaml.cs


示例10: ViewLinksViewModel

        /// <summary>
        /// Initializes a new instance of the <see cref="ViewLinksViewModel"/> class.
        /// </summary>
        /// <param name="linkViewModel">
        /// The link view model.
        /// </param>
        /// <param name="links">
        /// The links.
        /// </param>
        public ViewLinksViewModel(LinkViewModel linkViewModel, ObservableCollection<LinkViewModel> links)
        {
            this.Links = links;
            this.SelectedItem = linkViewModel;

            this.uiVisibility = Visibility.Visible;
        }
开发者ID:jlkalberer,项目名称:Linkslap.WP,代码行数:16,代码来源:ViewLinksViewModel.cs


示例11: SetBusyVisibility

 public static void SetBusyVisibility(Visibility visible, string text = null)
 {
     WindowWrapper.Current().Dispatcher.Dispatch(() =>
     {
         switch (visible)
         {
             case Visibility.Visible:
                 Instance.IsBusyVisible = true;
                 Instance.FindName(nameof(BusyScreen));
                 Instance.BusyText.Text = text ?? string.Empty;
                 if (VisualStateManager.GoToState(Instance, Instance.BusyVisualState.Name, true))
                 {
                     SystemNavigationManager.GetForCurrentView().AppViewBackButtonVisibility =
                         AppViewBackButtonVisibility.Collapsed;
                 }
                 break;
             case Visibility.Collapsed:
                 Instance.IsBusyVisible = false;
                 if (VisualStateManager.GoToState(Instance, Instance.NormalVisualState.Name, true))
                 {
                     BootStrapper.Current.UpdateShellBackButton();
                 }
                 break;
         }
     });
 }
开发者ID:xorch,项目名称:RemoteControllUWP,代码行数:26,代码来源:Shell.xaml.cs


示例12: ChangeVisibility

 // metoda zmienia visibility każdej zakładki,
 //index decyduje która zakładka ma zostac wybrana jako początkowa
 public void ChangeVisibility(int index=0,
     Visibility Login=Visibility.Collapsed,
     Visibility Tab=Visibility.Collapsed,
     Visibility UserAcc=Visibility.Collapsed,
     Visibility RoomsVis = Visibility.Collapsed,
     Visibility InstituteManagmentVis = Visibility.Collapsed,
     Visibility DictionaryVis = Visibility.Collapsed,
     Visibility InstituteDevicesList = Visibility.Collapsed,         
     Visibility InstituteWorkersList = Visibility.Collapsed,  
     Visibility RaportsVis = Visibility.Collapsed,
     Visibility LogoutVis= Visibility.Visible
     )
 {
     LoginControl.Visibility = Login;
     UserAccount.Visibility = UserAcc;
     Rooms.Visibility = RoomsVis;
     InstituteManagment.Visibility = InstituteManagmentVis;
     Dictionary.Visibility = DictionaryVis;
     InstituteDevicesManagment.Visibility = InstituteDevicesList;
     InstituteWorkersManagment.Visibility = InstituteWorkersList;
     Raports.Visibility = RaportsVis;
     MenuControl.Visibility = LogoutVis;
     TabControlMenu.SelectedIndex=index;
     TabControlMenu.Visibility = Tab;
 }
开发者ID:losinieckipiotr,项目名称:BD2Ti2015Projekt,代码行数:27,代码来源:MainWindow.xaml.cs


示例13: GetValueModelFor

        public ValueModel GetValueModelFor(Type mixinType, Visibility visibility)
        {
            ValueModel foundModel = null;
            foreach (ValueModel composite in this.valueModels)
            {
                if (typeof(ValueComposite).IsAssignableFrom(mixinType))
                {
                    if (mixinType == composite.CompositeType && composite.Visibility == visibility)
                    {
                        if (foundModel != null)
                        {
                            throw new AmbiguousTypeException(mixinType, foundModel.CompositeType, composite.CompositeType);
                        }

                        foundModel = composite;
                    }
                }
                else
                {
                    if (mixinType.IsAssignableFrom(composite.CompositeType) && composite.Visibility == visibility)
                    {
                        if (foundModel != null)
                        {
                            throw new AmbiguousTypeException(mixinType, foundModel.CompositeType, composite.CompositeType);
                        }
                        foundModel = composite;
                    }
                }
            }

            return foundModel;
        }
开发者ID:attila3453,项目名称:alsing,代码行数:32,代码来源:ValuesModel.cs


示例14: ListBoxItem_Selected_0

        private void ListBoxItem_Selected_0(object sender, RoutedEventArgs e)
        {
            cantGoForward = false;
            comp1Active = System.Windows.Visibility.Visible;
            comp2Active = System.Windows.Visibility.Hidden;
            comp3Active = System.Windows.Visibility.Hidden;
            comp4Active = System.Windows.Visibility.Hidden;
            comp5Active = System.Windows.Visibility.Hidden;

            opponent1.Visibility = System.Windows.Visibility.Visible;
            opponent1textBox.Visibility = System.Windows.Visibility.Visible;
            opponent1.IsEnabled = true;
            opponent2.Visibility = System.Windows.Visibility.Hidden;
            opponent2textBox.Visibility = System.Windows.Visibility.Hidden;
            opponent2.IsEnabled = false;
            opponent3.Visibility = System.Windows.Visibility.Hidden;
            opponent3textBox.Visibility = System.Windows.Visibility.Hidden;
            opponent3.IsEnabled = false;
            opponent4.Visibility = System.Windows.Visibility.Hidden;
            opponent4textBox.Visibility = System.Windows.Visibility.Hidden;
            opponent4.IsEnabled = false;
            opponent5.Visibility = System.Windows.Visibility.Hidden;
            opponent5textBox.Visibility = System.Windows.Visibility.Hidden;
            opponent5.IsEnabled = false;

        }
开发者ID:diaaanek,项目名称:blackjack-tamu-431,代码行数:26,代码来源:MultiPlayerOptions.xaml.cs


示例15: VisitModules

        public bool VisitModules(ModuleVisitor visitor, Visibility visibility)
        {
            // Visit modules in this layer
            foreach (ModuleInstance moduleInstance in this.moduleInstances)
            {
                if (!visitor.VisitModule(moduleInstance, moduleInstance.Model, visibility))
                {
                    return false;
                }
            }

            if (visibility == Visibility.Layer)
            {
                // Visit modules in this layer
                if (!this.VisitModules(visitor, Visibility.Application))
                {
                    return false;
                }

                // Visit modules in used layers
                return this.UsedLayersInstance.VisitModules(visitor);
            }

            return true;
        }
开发者ID:attila3453,项目名称:alsing,代码行数:25,代码来源:LayerInstance.cs


示例16: SettingsWindowViewModel

 public SettingsWindowViewModel()
 {
     m_close_command             = new DelegateCommand(OnCloseCommandExecuted);
     m_selected_language         = Settings.Language.Value;
     m_close_button_text         = Text.Close;
     m_warn_message_visibility   = Visibility.Collapsed;
 }
开发者ID:DarkDare,项目名称:wincompose,代码行数:7,代码来源:SettingsWindowViewModel.cs


示例17: CodeWithReturnValue

 public CodeWithReturnValue(bool overrided, bool @static, Visibility visibility, bool @virtual, string name, bool @abstract, string returnType)
     : base(@static, visibility, @virtual, name, @abstract)
 {
     ParameterValidator.ThrowIfArgumentNull(returnType, "tyreturnTypepe");
     ReturnType = returnType;
     Overrided = overrided;
 }
开发者ID:goncalod,项目名称:csharp,代码行数:7,代码来源:DeclarationWithReturnValue.cs


示例18: TagRefData

 public TagRefData(string name, uint offset, uint address, TagHierarchy allTags, Visibility showJumpTo, bool withClass, uint pluginLine)
     : base(name, offset, address, pluginLine)
 {
     _allTags = allTags;
     _withClass = withClass;
     _showJumpTo = showJumpTo;
 }
开发者ID:iBotPeaches,项目名称:Assembly,代码行数:7,代码来源:TagRefData.cs


示例19: CheckingTeacher

 public CheckingTeacher(Teacher Teacher, bool Checking, Visibility Visible)
 {
     this.Teacher = Teacher;
     this.Checking = Checking;
     this.Visible = Visible;
     this.Content = ((Domain.IDomainIdentity<Teacher>)Teacher).ID.ToString() + "-" + Teacher.Name;
 }
开发者ID:Eugenni,项目名称:mandarin,代码行数:7,代码来源:StorageEditor.cs


示例20: BooleanValuesConvertToCorrectVisibilityValues

        public void BooleanValuesConvertToCorrectVisibilityValues(bool value, Visibility expectedValue)
        {
            var converter = new BoolToVisibilityValueConverter();
            var actualValue = (Visibility)converter.Convert(value, null, null, null);

            Assert.AreEqual(expectedValue, actualValue);
        }
开发者ID:Neurosion,项目名称:SteamLauncher,代码行数:7,代码来源:BoolToVisibilityConverterTests.cs



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
C# VisioAutomation类代码示例发布时间:2022-05-24
下一篇:
C# VirtueName类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

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

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

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