本文整理汇总了C#中ServiceProvider.RunOnceAsync方法的典型用法代码示例。如果您正苦于以下问题:C# ServiceProvider.RunOnceAsync方法的具体用法?C# ServiceProvider.RunOnceAsync怎么用?C# ServiceProvider.RunOnceAsync使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ServiceProvider
的用法示例。
在下文中一共展示了ServiceProvider.RunOnceAsync方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: HackerWindow
public HackerWindow()
{
Program.HackerWindow = this;
processP = Program.ProcessProvider;
serviceP = Program.ServiceProvider;
networkP = Program.NetworkProvider;
InitializeComponent();
// Force the handle to be created
{ var handle = this.Handle; }
Program.HackerWindowHandle = this.Handle;
if (OSVersion.HasExtendedTaskbar)
{
// We need to call this here or we dont recieve the TaskbarButtonCreated WindowMessage
Windows7Taskbar.AllowWindowMessagesThroughUipi();
Windows7Taskbar.AppId = "ProcessHacker";
Windows7Taskbar.ProcessAppId = "ProcessHacker";
thumbButtonManager = new ThumbButtonManager(this);
thumbButtonManager.TaskbarButtonCreated += new EventHandler(thumbButtonManager_TaskbarButtonCreated);
}
this.AddEscapeToClose();
Logging.Logged += this.QueueMessage;
Settings.Refresh();
this.LoadWindowSettings();
this.LoadOtherSettings();
this.LoadControls();
this.LoadNotificationIcons();
Program.AppInstance = new ApplicationInstance();
Program.AppInstance.MainMenu = new MainMenuManager(mainMenu.MenuItems);
Program.AppInstance.MainMenu.Hacker = new MenuItemManager(hackerMenuItem.MenuItems);
Program.AppInstance.MainMenu.View = new MenuItemManager(viewMenuItem.MenuItems);
Program.AppInstance.MainMenu.Tools = new MenuItemManager(toolsMenuItem.MenuItems);
Program.AppInstance.MainMenu.Help = new MenuItemManager(helpMenu.MenuItems);
this.LoadPlugins();
if ((!Properties.Settings.Default.StartHidden && !Program.StartHidden) ||
Program.StartVisible)
{
this.Visible = true;
}
if (tabControl.SelectedTab == tabProcesses)
treeProcesses.Tree.Select();
this.LoadOther();
this.LoadStructs();
vistaMenu.DelaySetImageCalls = false;
vistaMenu.PerformPendingSetImageCalls();
serviceP.RunOnceAsync();
serviceP.Enabled = true;
_dontCalculate = false;
}
示例2: HackerWindow
public HackerWindow()
{
Program.HackerWindow = this;
processP = Program.ProcessProvider;
serviceP = Program.ServiceProvider;
networkP = Program.NetworkProvider;
InitializeComponent();
{ var handle = this.Handle; }
Program.HackerWindowHandle = this.Handle;
if (OSVersion.HasExtendedTaskbar)
{
Windows7Taskbar.AllowWindowMessagesThroughUipi();
Windows7Taskbar.AppId = "ProcessHacker";
Windows7Taskbar.ProcessAppId = "ProcessHacker";
thumbButtonManager = new ThumbButtonManager(this);
thumbButtonManager.TaskbarButtonCreated += new EventHandler(thumbButtonManager_TaskbarButtonCreated);
}
this.AddEscapeToClose();
Logging.Logged += this.QueueMessage;
Settings.Refresh();
this.LoadWindowSettings();
this.LoadOtherSettings();
this.LoadControls();
this.LoadNotificationIcons();
if ((!Properties.Settings.Default.StartHidden && !Program.StartHidden) ||
Program.StartVisible)
{
this.Visible = true;
}
if (tabControl.SelectedTab == tabProcesses)
treeProcesses.Tree.Select();
this.LoadOther();
this.LoadStructs();
vistaMenu.DelaySetImageCalls = false;
vistaMenu.PerformPendingSetImageCalls();
serviceP.RunOnceAsync();
serviceP.Enabled = true;
_dontCalculate = false;
}