Exemplo n.º 1
0
 /// <summary>
 /// This class should be created and passed into Application.Run( ... )
 /// </summary>
 public ChoApplicationContext(ChoApplicationHost appHost)
 {
     ChoGuard.ArgumentNotNull(appHost, "ApplicationHost");
     _appHost   = appHost;
     _mainForm  = appHost.GetMainWindowObject();
     _hasWindow = appHost.IsWindowApp;
     BuildDefaultContextMenu();
     this._components = new System.ComponentModel.Container();
     this.NotifyIcon  = new ChoNotifyIcon(this._components);
     PreInitializeContext(appHost);
     ChoApplication.RaiseAfterNotifyIconConstructed(NotifyIcon);
     InitializeContext(appHost);
     _defaultTrayTipMsg = "{0} is running...".FormatString(ChoGlobalApplicationSettings.Me.ApplicationName);
 }