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

C# IPluginHost类代码示例

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

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



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

示例1: BulletHeightFieldShapeNode

        public BulletHeightFieldShapeNode(IPluginHost host)
        {
            this.FHost = host;

            this.FHost.CreateValueInput("Resolution", 2, null, TSliceMode.Dynamic, TPinVisibility.True, out this.FPinInResolution);
            this.FPinInResolution.SetSubType2D(2, double.MaxValue, 1, 5, 5, false, false, true);
        }
开发者ID:sunep,项目名称:dx11-vvvv,代码行数:7,代码来源:BulletHeightfieldNode.cs


示例2: ConfigDialog

        public ConfigDialog(IPluginHost pluginHost)
        {
            InitializeComponent();
            m_PluginHost = pluginHost;

            if (File.Exists("StrengthReportLayouts.xml")) {
                m_LayoutBox = LayoutBox.LoadFromFile("StrengthReportLayouts.xml");
            } else {
                m_LayoutBox = LayoutBox.LoadFromString(Resources.LayoutsDefault);
            }

            foreach (Layout l in m_LayoutBox)
                layoutBoxBindingSource.Add(l);

            if (File.Exists("StrengthReportTemplates.xml")) {
                m_TemplateBox = TemplateBox.LoadFromFile("StrengthReportTemplates.xml");
            } else {
                m_TemplateBox = TemplateBox.LoadFromString(Resources.TemplatesDefault);
            }

            foreach (Template l in m_TemplateBox)
                templatesBinginSource.Add(l);

            tabFormat.SelectedIndex = 1;
        }
开发者ID:jonbws,项目名称:strengthreport,代码行数:25,代码来源:ConfigDialog.cs


示例3: KeePassRPCService

 public KeePassRPCService(IPluginHost host, string[] standardIconsBase64, KeePassRPCExt plugin)
 {
     KeePassRPCPlugin = plugin;
     PluginVersion = KeePassRPCExt.PluginVersion;
     this.host = host;
     _standardIconsBase64 = standardIconsBase64;
 }
开发者ID:krbvroc1,项目名称:KeeFox,代码行数:7,代码来源:KeePassRPCService.cs


示例4: DX11CubeRendererNode

        public DX11CubeRendererNode(IPluginHost FHost, IIOFactory iofactory)
        {
            string ename = DX11EnumFormatHelper.NullDeviceFormats.GetEnumName(FormatSupport.RenderTarget);

            InputAttribute tattr = new InputAttribute("Target Format");
            tattr.IsSingle = true;
            tattr.EnumName = ename;
            tattr.DefaultEnumEntry = "R8G8B8A8_UNorm";

            this.FInFormat = iofactory.CreateDiffSpread<EnumEntry>(tattr);

            this.depthmanager = new DepthBufferManager(FHost, iofactory);

            this.lookats.Add(new Vector3(1.0f, 0.0f, 0.0f));
            this.lookats.Add(new Vector3(-1.0f, 0.0f, 0.0f));
            this.lookats.Add(new Vector3(0.0f, 1.0f, 0.0f));

            this.lookats.Add(new Vector3(0.0f, - 1.0f, 0.0f));
            this.lookats.Add(new Vector3(0.0f, 0.0f, 1.0f));
            this.lookats.Add(new Vector3(0.0f, 0.0f, -1.0f));

            this.upvectors.Add(new Vector3(0.0f, 1.0f, 0.0f));
            this.upvectors.Add(new Vector3(0.0f, 1.0f, 0.0f));
            this.upvectors.Add(new Vector3(0.0f, 0.0f, -1.0f));
            this.upvectors.Add(new Vector3(0.0f, 0.0f, 1.0f));
            this.upvectors.Add(new Vector3(0.0f, 1.0f, 0.0f));
            this.upvectors.Add(new Vector3(0.0f, 1.0f, 0.0f));
        }
开发者ID:kopffarben,项目名称:dx11-vvvv,代码行数:28,代码来源:DX11CubeRendererNode.cs


示例5: DX11PreviewNode

 public DX11PreviewNode(IPluginHost host, IIOFactory iofactory)
 {
     this.ctrl = new Control();
      this.ctrl.Dock = DockStyle.Fill;
      this.ctrl.Resize += new EventHandler(ctrl_Resize);
      this.ctrl.BackColor = System.Drawing.Color.Black;
 }
开发者ID:sebllll,项目名称:dx11-vvvv,代码行数:7,代码来源:DX11PreviewNode.cs


示例6: ScreenRecordForm

        public ScreenRecordForm( IPluginHost pluginHost )
            : base(pluginHost)
        {
            this.StickyWindow = new DroidExplorer.UI.StickyWindow ( this );
            CommonResolutions = GetCommonResolutions ( );
            InitializeComponent ( );

            var defaultFile = "screenrecord_{0}_{1}.mp4".With ( this.PluginHost.Device, DateTime.Now.ToString ( "yyyy-MM-dd-hh" ) );
            this.location.Text = "/sdcard/{0}".With ( defaultFile );

            var resolution = new VideoSize ( PluginHost.CommandRunner.GetScreenResolution ( ) );
            var sizes = CommonResolutions.Concat ( new List<VideoSize> { resolution } ).OrderBy ( x => x.Size.Width ).Select ( x => x ).ToList ( );
            resolutionList.DataSource = sizes;
            resolutionList.DisplayMember = "Display";
            resolutionList.ValueMember = "Size";
            resolutionList.SelectedItem = resolution;

            rotateList.DataSource = GetRotateArgumentsList ( );
            rotateList.DisplayMember = "Display";
            rotateList.ValueMember = "Arguments";

            var bitrates = new List<BitRate> ( );

            for ( int i = 1; i < 25; i++ ) {
                bitrates.Add ( new BitRate ( i ) );
            }

            bitrateList.DataSource = bitrates;
            bitrateList.DisplayMember = "Display";
            bitrateList.ValueMember = "Value";
            bitrateList.SelectedItem = bitrates.Single ( x => x.Mbps == 4 );
            var ts = new TimeSpan ( 0, 0, 0, timeLimit.Value, 0 );
            displayTime.Text = ts.ToString ( );
        }
开发者ID:camalot,项目名称:droidexplorer,代码行数:34,代码来源:ScreenRecordForm.cs


示例7: Decrypt

        public static sFolder Decrypt(sFile item, int blockSize, IPluginHost pluginHost)
        {
            sFolder unpacked = new sFolder();
            unpacked.files = new List<sFile>();

            byte[] data = File.ReadAllBytes(item.path);
            int numBlocks = data.Length / blockSize;

            for (int i = 0; i < numBlocks; i++)
            {
                byte[] block = new byte[blockSize];
                Array.Copy(data, i * blockSize, block, 0, blockSize);
                Decrypt(ref block);
                Array.Copy(block, 0, data, i * blockSize, blockSize);
            }

            string fileout = pluginHost.Get_TempFile();
            File.WriteAllBytes(fileout, data);

            sFile newItem = new sFile();
            newItem.path = fileout;
            newItem.offset = 0;
            newItem.name = item.name;
            newItem.size = (uint)data.Length;
            unpacked.files.Add(newItem);

            return unpacked;
        }
开发者ID:MetLob,项目名称:tinke,代码行数:28,代码来源:Encryption.cs


示例8: DX11RendererNode

        public DX11RendererNode(IPluginHost host, IIOFactory iofactory,IHDEHost hdehost)
        {
            InitializeComponent();
            this.FHost = host;
            this.hde = hdehost;

            //this.hde.BeforeComponentModeChange += new ComponentModeEventHandler(hde_BeforeComponentModeChange);

            this.Resize += DX11RendererNode_Resize;
            this.Load += new EventHandler(DX11RendererNode_Load);
            this.Click += new EventHandler(DX11RendererNode_Click);
            this.MouseEnter += new EventHandler(DX11RendererNode_MouseEnter);
            this.MouseLeave += new EventHandler(DX11RendererNode_MouseLeave);
            this.LostFocus += new EventHandler(DX11RendererNode_LostFocus);
            this.MouseWheel += new System.Windows.Forms.MouseEventHandler(DX11RendererNode_MouseWheel);
            this.BackColor = Color.Black;
            Touchdown += OnTouchDownHandler;
            Touchup += OnTouchUpHandler;
            TouchMove += OnTouchMoveHandler;

            this.depthmanager = new DepthBufferManager(host,iofactory);

            ConfigAttribute bbAttr = new ConfigAttribute("Back Buffer Format");
            bbAttr.IsSingle = true;
            bbAttr.EnumName = DX11EnumFormatHelper.NullDeviceFormats.GetEnumName(FormatSupport.BackBufferCast);
            bbAttr.DefaultEnumEntry = DX11EnumFormatHelper.NullDeviceFormats.GetAllowedFormats(FormatSupport.BackBufferCast)[0];

            this.FCfgBackBufferFormat = iofactory.CreateDiffSpread<EnumEntry>(bbAttr);
            this.FCfgBackBufferFormat[0] = new EnumEntry(DX11EnumFormatHelper.NullDeviceFormats.GetEnumName(FormatSupport.BackBufferCast), 0);
        }
开发者ID:kopffarben,项目名称:dx11-vvvv,代码行数:30,代码来源:DX11RendererNode_ctrl.cs


示例9: Initialise

 public override bool Initialise(IPluginHost host)
 {
     // TODO: Implement this correctly
     Host = host;
     this.Log().Debug("Initialised plugin. Plugin version = {0}, Host version = {1}", Version, Host.Version);
     return true;
 }
开发者ID:sensaura-public,项目名称:senshub,代码行数:7,代码来源:Plugin.cs


示例10: FlashRecovery

        /// <summary>
        /// Initializes a new instance of the <see cref="FlashRecovery" /> class.
        /// </summary>
        /// <param name="host">The host.</param>
        public FlashRecovery( IPluginHost host )
            : base(host)
        {
            this.PluginHost = host;

              CommandRunner.Instance.DeviceStateChanged += new EventHandler<DeviceEventArgs> ( CommandRunner_DeviceStateChanged );
        }
开发者ID:camalot,项目名称:droidexplorer,代码行数:11,代码来源:FlashRecovery.cs


示例11: MyView

        public MyView(IPluginHost myHost, IPlugin myPlugin, Webservice.IWebserviceClient aWebserviceClient, IPlugin aWebservicePlugin)
        {
            InitializeComponent();

            _aWebserviceClient = aWebserviceClient;
            _myHost = myHost;
            _myPlugin = myPlugin;
            _aStreamManagerAll = new StreamManager(aWebserviceClient);
            _aStreamManagerFavorites = new StreamManager(aWebserviceClient);
            _aWebservicePlugin = aWebservicePlugin;

            //Init Binding
            ICollectionView viewAll = CollectionViewSource.GetDefaultView(_aStreamManagerAll.GetStreams());
            new TextSearchFilter(viewAll, textBoxSearch);

            ICollectionView viewFavorites = CollectionViewSource.GetDefaultView(_aStreamManagerFavorites.GetStreams());
            new TextSearchFilter(viewFavorites, textBoxSearch);

            listView.DataContext = viewAll;
            Binding bindAll = new Binding();
            listView.SetBinding(System.Windows.Controls.ItemsControl.ItemsSourceProperty, bindAll);

            listViewFavorites.DataContext = viewFavorites;
            Binding bindFav = new Binding();
            listViewFavorites.SetBinding(System.Windows.Controls.ItemsControl.ItemsSourceProperty, bindFav);

            _aStreamManagerAll.Load(Environment.GetFolderPath(Environment.SpecialFolder.Personal) + "\\Gamenoise\\streamsAll.xml");
            _aStreamManagerFavorites.Load(Environment.GetFolderPath(Environment.SpecialFolder.Personal) + "\\Gamenoise\\streamsFavorite.xml");
        }
开发者ID:mhack,项目名称:gamenoise,代码行数:29,代码来源:MyView.xaml.cs


示例12: Initialize

        public void Initialize(IPluginHost pluginHost, string gameCode)
        {
            this.pluginHost = pluginHost;
            this.gameCode = gameCode;

            pal_id = new List<int>();
            pal_id.Add(0x07);
            pal_id.Add(0xD7);
            pal_id.Add(0xDA);
            pal_id.Add(0xDC);
            pal_id.Add(0xDE);
            pal_id.Add(0xE0);
            pal_id.Add(0xE2);
            pal_id.Add(0xE4);
            pal_id.Add(0xE6);
            pal_id.Add(0xF0);
            pal_id.Add(0xF2);
            pal_id.Add(0xF4);
            pal_id.Add(0xFC);
            pal_id.Add(0xFF);
            pal_id.Add(0x104);
            pal_id.Add(0x108);
            pal_id.Add(0x10A);
            pal_id.Add(0x10D);
            pal_id.Add(0x10F);
            pal_id.Add(0x111);
            pal_id.Add(0x113);
            pal_id.Add(0x118);
        }
开发者ID:MetLob,项目名称:tinke,代码行数:29,代码来源:Main.cs


示例13: ApkExtension

 /// <summary>
 /// Initializes a new instance of the <see cref="Shell"/> class.
 /// </summary>
 /// <param name="host">The host.</param>
 public ApkExtension(IPluginHost host)
     : base(host)
 {
     if ( host != null ) {
         this.PluginHost.RegisterFileTypeIconHandler(".apk", this);
     }
 }
开发者ID:camalot,项目名称:droidexplorer,代码行数:11,代码来源:ApkExtension.cs


示例14: Initialize

        public override bool Initialize(IPluginHost host)
        {
            if(m_host != null) Terminate();
            if(host == null) return false;
            if(NativeLib.IsUnix()) return false;

            // #pragma warning disable 162
            // if(PwDefs.Version32 <= 0x02010500)
            // {
            //	MessageService.ShowWarning("IOProtocolExt",
            //		"This plugin requires KeePass 2.16 or higher.");
            //	return false;
            // }
            // #pragma warning restore 162

            m_host = host;
            m_host.TriggerSystem.RaisingEvent += this.OnEcasEvent;

            m_tsSep = new ToolStripSeparator();
            m_host.MainWindow.ToolsMenu.DropDownItems.Add(m_tsSep);

            m_tsOptions = new ToolStripMenuItem(IopDefs.ProductName + " Options...");
            m_tsOptions.Click += this.OnOptions;
            m_host.MainWindow.ToolsMenu.DropDownItems.Add(m_tsOptions);

            m_wrcWinScp = new WinScpWebRequestCreator();
            m_wrcWinScp.Register();

            return true;
        }
开发者ID:blackbinarych,项目名称:IOProtocolExt,代码行数:30,代码来源:IOProtocolExtExt.cs


示例15: Initialize

        public override bool Initialize( IPluginHost host )
        {
            if ( host == null ) return false;
            m_host = host;

            // Get a reference to the 'Tools' menu item container
            ToolStripItemCollection tsMenu = m_host.MainWindow.ToolsMenu.DropDownItems;

            // Add a separator at the bottom
            m_tsSeparator = new ToolStripSeparator();
            tsMenu.Add( m_tsSeparator );

            // Add menu item 'KeePassCompare'
            m_tsmiMenuItem = new ToolStripMenuItem();
            m_tsmiMenuItem.Text = "KeePassCompare Compare!";
            m_tsmiMenuItem.Click += this.OnMenuCompare;
            tsMenu.Add( m_tsmiMenuItem );

            // Add menu item 'KeePassCompare'
            m_tsmiMenuItem2 = new ToolStripMenuItem();
            m_tsmiMenuItem2.Text = "KeePassCompare Reset Colours";
            m_tsmiMenuItem2.Click += this.OnResetColors;
            tsMenu.Add( m_tsmiMenuItem2 );

            return true;
        }
开发者ID:CestLaGalere,项目名称:KeePassCompare,代码行数:26,代码来源:KeePassCompareExt.cs


示例16: PluginManager

 public PluginManager(IPluginHost _host, String _pluginAppPath, String _configFiletype = "*.json")
 {
     Host = _host;
     PluginAppPath = _pluginAppPath;
     ConfigFiletype = _configFiletype;
     Plugins = LoadPlugins();
 }
开发者ID:rasadeyan,项目名称:RestlessHoneySeeker,代码行数:7,代码来源:PluginManager.cs


示例17: Initialize

		public override bool Initialize(IPluginHost host)
		{
			Contract.Requires(host != null);

			this.host = host;

			ctxEntryShowQRCode = new ToolStripMenuItem
			{
				Image = Properties.Resources.icon,
				Text = CONTEXT_MENU_ITEM_LABEL
			};
			dynQRCodes = new DynamicMenu(ctxEntryShowQRCode.DropDownItems);
			dynQRCodes.MenuClick += OnShowQRCode;

			var insertAfterIndex = host.MainWindow.EntryContextMenu.Items.IndexOfKey(INSERT_AFTER_ENTRY_KEY);
			if (insertAfterIndex != -1)
			{
				//insert after "Save Attachements"
				host.MainWindow.EntryContextMenu.Items.Insert(insertAfterIndex + 1, ctxEntryShowQRCode);
			}
			else
			{
				//add at the end
				host.MainWindow.EntryContextMenu.Items.Add(ctxEntryShowQRCode);
			}
			host.MainWindow.EntryContextMenu.Opening += OnEntryContextMenuOpening;

			return true;
		}
开发者ID:KN4CK3R,项目名称:KeePassQRCodeView,代码行数:29,代码来源:KeePassQRCodeViewExt.cs


示例18: iTXT

        public iTXT(byte[] text, IPluginHost pluginHost, int id)
        {
            InitializeComponent();

            // TextBox parameter
            this.txtBox.Dock = DockStyle.Top;
            this.txtBox.Font = new Font(FontFamily.GenericMonospace, 11);
            this.txtBox.HideSelection = false;
            this.txtBox.Multiline = true;
            this.txtBox.WordWrap = this.checkWordWrap.Checked;
            this.txtBox.ScrollBars = ScrollBars.Both;
            this.txtBox.Size = new Size(510, 466);

            this.pluginHost = pluginHost;
            this.id = id;
            this.text = text;

            // TODO: Compare preamble with supported encodings.
            if ((text[0] == 0xFE && text[1] == 0xFF) || (text[0] == 0xFF && text[1] == 0xFE))
                comboEncod.SelectedIndex = 2;
            else if (BitConverter.ToUInt16(text, 0) == 0xBBEF)
                comboEncod.SelectedIndex = 4;
            else
                comboEncod.SelectedIndex = 1;

            ReadLanguage();
        }
开发者ID:MetLob,项目名称:tinke,代码行数:27,代码来源:iTXT.cs


示例19: DX11AbstractMeshNode

        public DX11AbstractMeshNode(IPluginHost Host)
        {
            //assign host
            this.FHost = Host;

            this.SetInputs();
        }
开发者ID:hameleon-ed,项目名称:dx11-vvvv,代码行数:7,代码来源:DX11AbstractMeshNode.cs


示例20: Unpack

        public static sFolder Unpack(string file, IPluginHost pluginHost)
        {
            BinaryReader br = new BinaryReader(File.OpenRead(file));
            sFolder unpacked = new sFolder();
            unpacked.files = new List<sFile>();

            uint num_files = (br.ReadUInt32() / 0x04) - 1;
            br.ReadUInt32(); // Pointer table
            for (int i = 0; i < num_files; i++)
            {
                uint startOffset = br.ReadUInt32();
                long currPos = br.BaseStream.Position;
                br.BaseStream.Position = startOffset;

                sFile newFile = new sFile();
                newFile.name = "File " + (i + 1).ToString("X") + ".bin";
                newFile.offset = startOffset + 4;
                newFile.path = file;
                newFile.size = br.ReadUInt32();

                br.BaseStream.Position = currPos;
                unpacked.files.Add(newFile);
            }

            br.Close();
            return unpacked;
        }
开发者ID:MetLob,项目名称:tinke,代码行数:27,代码来源:PACK.cs



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

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