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

C# IPreferenceFolder类代码示例

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

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



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

示例1: QueryAdapter

 public object QueryAdapter(IPreferenceFolder folder, Type type) {
     Debug.Assert(_originalFolder.Id == folder.Id);
     if (type == typeof(ITerminalSessionOptions))
         return folder == _originalFolder ? _originalOptions : new TerminalSessionOptions(folder).Import(_originalOptions);
     else
         return null;
 }
开发者ID:Ricordanza,项目名称:poderosa,代码行数:7,代码来源:TerminalSessionOptions.cs


示例2: InitializePreference

 public void InitializePreference(IPreferenceBuilder builder, IPreferenceFolder folder) {
     _schemeTemplate = builder.DefineFolderArray(folder, this, "scheme");
     _preferenceFolderArray = folder.FindChildFolderArray("scheme");
     Debug.Assert(_preferenceFolderArray != null);
     _namePreference = builder.DefineStringValue(_schemeTemplate, "name", "", null);
     _promptPreference = builder.DefineStringValue(_schemeTemplate, "prompt", GenericShellScheme.DEFAULT_PROMPT_REGEX, null);
     _backspacePreference = builder.DefineStringValue(_schemeTemplate, "backspace", "", null);
     _commandListPreference = builder.DefineStringValue(_schemeTemplate, "commands", "", null);
 }
开发者ID:Ricordanza,项目名称:poderosa,代码行数:9,代码来源:ShellScheme.cs


示例3: Commit

 public override bool Commit(IPreferenceFolder[] values) {
     Debug.Assert(_panel != null);
     return _panel.Commit((IProtocolOptions)values[0].QueryAdapter(typeof(IProtocolOptions)), (IKeyAgentOptions)values[1].QueryAdapter(typeof(IKeyAgentOptions)));
 }
开发者ID:Ricordanza,项目名称:poderosa,代码行数:4,代码来源:SSHOptionPanel.cs


示例4: QueryAdapter

 public object QueryAdapter(IPreferenceFolder folder, Type type)
 {
     return null;
 }
开发者ID:FNKGino,项目名称:poderosa,代码行数:4,代码来源:SSHKnownHosts.cs


示例5: InitiUI

 public abstract void InitiUI(IPreferenceFolder[] values);
开发者ID:VirusFree,项目名称:Poderosa,代码行数:1,代码来源:OptionDialogPlugin.cs


示例6: QueryAdapter

            public override object QueryAdapter(IPreferenceFolder folder, Type adapter)
            {
                //Snapshotに対するアクションがあるので、folder==_folderの比較ではアウト
                if (adapter == typeof(IUserFriendlyInterface)) {
                    if (_folder == folder)
                        return this;
                    else if (folder.Id == _folder.Id)
                        return this.CloneFor(folder);
                }

                //失敗ケース
                return null;
            }
开发者ID:FNKGino,项目名称:poderosa,代码行数:13,代码来源:PreferencesT.cs


示例7: InitializePreference

 public override void InitializePreference(IPreferenceBuilder builder, IPreferenceFolder folder)
 {
     base.InitializePreference(builder, folder);
     _i = builder.DefineIntValue(folder, "i", 10, new PreferenceItemValidator<int>(ValidateI));
     _s = builder.DefineStringValue(folder, "s", "bobo", new PreferenceItemValidator<string>(ValidateS));
 }
开发者ID:FNKGino,项目名称:poderosa,代码行数:6,代码来源:PreferencesT.cs


示例8: OnPreferenceImport

 public void OnPreferenceImport(IPreferenceFolder oldvalues, IPreferenceFolder newvalues)
 {
     _lastImportedFolder = newvalues;
     _count++;
 }
开发者ID:FNKGino,项目名称:poderosa,代码行数:5,代码来源:PreferencesT.cs


示例9: InitializePreference

 public void InitializePreference(IPreferenceBuilder builder, IPreferenceFolder folder)
 {
     _modifyCursorKeys = builder.DefineIntValue(folder, "modifyCursorKeys", DEFAULT_MODIFY_CURSOR_KEYS, PreferenceValidatorUtil.PositiveIntegerValidator);
 }
开发者ID:junamai2000,项目名称:poderosa,代码行数:4,代码来源:XTerm.cs


示例10: InitPreference

 internal static void InitPreference(IPreferenceBuilder builder, IPreferenceFolder window_root)
 {
     _aboutBoxID = builder.DefineStringValue(window_root, "aboutBoxFactoryID", "default", null);
 }
开发者ID:VirusFree,项目名称:Poderosa,代码行数:4,代码来源:AboutBoxEx.cs


示例11: Commit

 public override bool Commit(IPreferenceFolder[] values)
 {
     Debug.Assert(_panel != null);
     return _panel.Commit(OptionDialogPlugin.Instance.CommandManager.GetKeyBinds(values[0]));
 }
开发者ID:FNKGino,项目名称:poderosa,代码行数:5,代码来源:CommandOptionPanel.cs


示例12: InitiUI

 public override void InitiUI(IPreferenceFolder[] values)
 {
     if (_panel == null)
         _panel = new CommandOptionPanel();
     _panel.InitUI(OptionDialogPlugin.Instance.CommandManager.GetKeyBinds(values[0]));
 }
开发者ID:FNKGino,项目名称:poderosa,代码行数:6,代码来源:CommandOptionPanel.cs


示例13: InitializePreference

        //IPreferencesupplier
        public void InitializePreference(IPreferenceBuilder builder, IPreferenceFolder folder) {
            _originalFolder = folder;
            _originalOptions = new TerminalOptions(folder);
            _originalOptions.DefineItems(builder);


            //defaultRenderProfileのリセットをする
            _originalFolder.AddChangeListener(this);
        }
开发者ID:Ricordanza,项目名称:poderosa,代码行数:10,代码来源:Options.cs


示例14: TerminalOptions

 public TerminalOptions(IPreferenceFolder folder)
     : base(folder) {
 }
开发者ID:Ricordanza,项目名称:poderosa,代码行数:3,代码来源:Options.cs


示例15: OnPreferenceImport

        //必ずimportされるという前提なのでちょっと危険
        public void OnPreferenceImport(IPreferenceFolder oldvalues, IPreferenceFolder newvalues) {
            ITerminalEmulatorOptions opt = (ITerminalEmulatorOptions)newvalues.QueryAdapter(typeof(ITerminalEmulatorOptions));

            //DefaultRenderProfile
            GEnv.DefaultRenderProfile = opt.CreateRenderProfile();

            //必要なTerminalSessionにApplyTerminalOptions
            ISessionManager sm = TerminalEmulatorPlugin.Instance.GetSessionManager();
            foreach (ISession session in sm.AllSessions) {
                IAbstractTerminalHost ts = (IAbstractTerminalHost)session.GetAdapter(typeof(IAbstractTerminalHost));
                if (ts != null) {
                    TerminalControl tc = ts.TerminalControl;
                    if (tc != null) {
                        tc.ApplyTerminalOptions(opt);
                    }
                }
            }

            //ASCIIWordBreakTable
            ASCIIWordBreakTable table = ASCIIWordBreakTable.Default;
            table.Reset();
            foreach (char ch in opt.AdditionalWordElement)
                table.Set(ch, ASCIIWordBreakTable.LETTER);

            //キーバインド系をリセット
            TerminalEmulatorPlugin.Instance.CustomKeySettings.Reset(opt);

            //KeepAliveのリフレッシュ
            TerminalEmulatorPlugin.Instance.KeepAlive.Refresh(opt.KeepAliveInterval);

            _originalOptions.ResetParseKeyFlag();
        }
开发者ID:Ricordanza,项目名称:poderosa,代码行数:33,代码来源:Options.cs


示例16: ProtocolOptions

 public ProtocolOptions(IPreferenceFolder folder)
     : base(folder) {
 }
开发者ID:Ricordanza,项目名称:poderosa,代码行数:3,代码来源:ProtocolOptions.cs


示例17: OnPreferenceImport

            public void OnPreferenceImport(IPreferenceFolder oldvalues, IPreferenceFolder newvalues) {
                ICoreServicePreference nv = (ICoreServicePreference)newvalues.QueryAdapter(typeof(ICoreServicePreference));
                WindowManagerPlugin.Instance.ReloadPreference(nv);
                _adapter.ClearSplitModifierCheckedFlag();

                //言語が変わっていたら...
                Language lang = nv.Language;
                if (lang != ((ICoreServicePreference)oldvalues.QueryAdapter(typeof(ICoreServicePreference))).Language) {
                    Debug.WriteLine("Change Language");
                    WindowManagerPlugin.Instance.PoderosaWorld.Culture.SetCulture(CoreServicePreferenceAdapter.LangToCulture(lang));
                }
            }
开发者ID:Ricordanza,项目名称:poderosa,代码行数:12,代码来源:WindowPreference.cs


示例18: InitializePreference

 public void InitializePreference(IPreferenceBuilder builder, IPreferenceFolder folder) {
     _originalFolder = folder;
     _originalOptions = new ProtocolOptions(folder);
     _originalOptions.DefineItems(builder);
 }
开发者ID:Ricordanza,项目名称:poderosa,代码行数:5,代码来源:ProtocolOptions.cs


示例19: InitializePreference

        public void InitializePreference(IPreferenceBuilder builder, IPreferenceFolder folder) {
            _originalFolder = folder;
            _adapter = new CoreServicePreferenceAdapter(folder);
            _adapter.DefineItems(builder);

            AboutBoxUtil.InitPreference(builder, folder);

            _windowTemplatePreference = builder.DefineFolderArray(folder, this, "mainwindow");
            _windowArrayPreference = folder.FindChildFolderArray("mainwindow");
            Debug.Assert(_windowArrayPreference != null);

            _windowPositionPreference = builder.DefineStringValue(_windowTemplatePreference, "position", "", null);
            _windowSplitFormatPreference = builder.DefineStringValue(_windowTemplatePreference, "format", "", null);
            _toolBarFormatPreference = builder.DefineStringValue(_windowTemplatePreference, "toolbar", "", null);
            _tabRowCountPreference = builder.DefineIntValue(_windowTemplatePreference, "tabrowcount", 1, null);

            //add listener
            folder.AddChangeListener(new ChangeListener(_adapter));
        }
开发者ID:Ricordanza,项目名称:poderosa,代码行数:19,代码来源:WindowPreference.cs


示例20: QueryAdapter

 public object QueryAdapter(IPreferenceFolder folder, Type type) {
     if (type == typeof(ICoreServicePreference))
         return folder == _originalFolder ? _adapter : new CoreServicePreferenceAdapter(folder).Import(_adapter);
     else if (type == typeof(IWindowPreference)) {
         Debug.Assert(folder == _originalFolder); //IWindowPreferenceについてはSnapshotサポートせず
         return this;
     }
     else
         return null;
 }
开发者ID:Ricordanza,项目名称:poderosa,代码行数:10,代码来源:WindowPreference.cs



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
C# IPreferences类代码示例发布时间:2022-05-24
下一篇:
C# IPredicateExpression类代码示例发布时间: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