public static void Main(string[] args) { var generator = new global::Eto.Platform.Wpf.Generator(); generator.Add <IDialog> (() => new Controls.CustomDialog()); generator.Add <IForm> (() => new Controls.CustomForm()); //generator.Add<IWebView>(() => new Controls.CefSharpWebViewHandler()); generator.Add <IWebView>(() => new Controls.CefGlueWebViewHandler()); generator.Add <IJabbRApplication>(() => new Controls.JabbRApplicationHandler()); Style.Add <Controls.CustomForm> (null, handler => { AddResources(handler.Control); }); Style.Add <Controls.CustomDialog> (null, handler => { AddResources(handler.Control); }); Style.Add <TreeViewHandler> ("channelList", handler => { handler.Control.BorderThickness = new sw.Thickness(0); }); Style.Add <TreeViewHandler> ("userList", handler => { handler.Control.BorderThickness = new sw.Thickness(0); }); var app = new JabbRApplication(generator); app.Initialized += CheckForNewVersion; app.Run(args); }
public static void Main(string[] args) { ServicePointManager.ServerCertificateValidationCallback = Validator; var generator = Generator.Detect; generator.Add <IJabbRApplication>(() => new JabbRApplicationHandler()); var app = new JabbRApplication(); app.Run(args); }
public static void Main(string[] args) { ServicePointManager.ServerCertificateValidationCallback = Validator; var generator = new Eto.Platform.GtkSharp.Generator(); generator.Add <IJabbRApplication>(() => new JabbRApplicationHandler()); var app = new JabbRApplication(generator); app.Run(args); }
public static void Main (string[] args) { Generator.Detect.AddAssembly (typeof (MainClass).Assembly); Style.Add<Controls.CustomForm> (null, handler => { AddResources (handler.Control); }); Style.Add<Controls.CustomDialog> (null, handler => { AddResources (handler.Control); }); var app = new JabbRApplication(); //app.Initialized += CheckForNewVersion; app.Run (args); }
static void Main(string[] args) { #if DEBUG Debug.Listeners.Add (new ConsoleTraceListener()); #endif var generator = Generator.Detect; generator.Add <IJabbRApplication>(() => new JabbRApplicationHandler()); NSApplication.CheckForIllegalCrossThreadCalls = false; Style.Add<TreeViewHandler>("channelList", h => { h.Control.Delegate = new CustomTreeViewDelegate { Handler = h, AllowGroupSelection = true }; h.Control.SelectionHighlightStyle = NSTableViewSelectionHighlightStyle.SourceList; h.Scroll.BorderType = NSBorderType.NoBorder; }); Style.Add<FormHandler>("mainForm", h => { h.Control.CollectionBehavior |= NSWindowCollectionBehavior.FullScreenPrimary; }); Style.Add<ApplicationHandler>("application", h => { h.EnableFullScreen(); }); Style.Add<TreeViewHandler>("userList", h => { h.Control.Delegate = new CustomTreeViewDelegate { Handler = h }; h.Control.SelectionHighlightStyle = NSTableViewSelectionHighlightStyle.SourceList; h.Scroll.BorderType = NSBorderType.NoBorder; }); Style.Add<WebViewHandler>(null, h => { h.Control.Preferences.UsesPageCache = false; }); var app = new JabbRApplication(); app.Initialized += delegate { #if DEBUG NSUserDefaults.StandardUserDefaults.SetBool (true, "WebKitDeveloperExtras"); NSUserDefaults.StandardUserDefaults.Synchronize(); #endif }; app.Run(args); }
static void Main(string[] args) { #if DEBUG Debug.Listeners.Add(new ConsoleTraceListener()); #endif // so we don't link out mono.runtime for detection var generator = Generator.Detect; generator.Add <IJabbRApplication>(() => new JabbRApplicationHandler()); NSApplication.CheckForIllegalCrossThreadCalls = false; Style.Add <TreeViewHandler>("channelList", handler => { handler.Control.Delegate = new CustomTreeViewDelegate { Handler = handler, AllowGroupSelection = true }; handler.Control.SelectionHighlightStyle = NSTableViewSelectionHighlightStyle.SourceList; handler.Scroll.BorderType = NSBorderType.NoBorder; }); Style.Add <FormHandler>("mainForm", handler => handler.Control.CollectionBehavior |= NSWindowCollectionBehavior.FullScreenPrimary); Style.Add <ApplicationHandler>("application", handler => handler.EnableFullScreen()); Style.Add <TreeViewHandler>("userList", handler => { handler.Control.Delegate = new CustomTreeViewDelegate { Handler = handler }; handler.Control.SelectionHighlightStyle = NSTableViewSelectionHighlightStyle.SourceList; handler.Scroll.BorderType = NSBorderType.NoBorder; }); Style.Add <WebViewHandler>(null, handler => handler.Control.Preferences.UsesPageCache = false); var app = new JabbRApplication(); app.Initialized += delegate { #if DEBUG NSUserDefaults.StandardUserDefaults.SetBool(true, "WebKitDeveloperExtras"); NSUserDefaults.StandardUserDefaults.Synchronize(); #endif }; app.Run(args); }