public MainWindow() { Instance = this; InitializeComponent(); Title = Title.Put("E*TRADE"); Closing += OnClosing; _ordersWindow.MakeHideable(); _securitiesWindow.MakeHideable(); _stopOrdersWindow.MakeHideable(); _portfoliosWindow.MakeHideable(); _myTradesWindow.MakeHideable(); var guilistener = new GuiLogListener(_logControl); guilistener.Filters.Add(msg => msg.Level > LogLevels.Debug); _logManager.Listeners.Add(guilistener); var location = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location); var path = Path.Combine(location ?? "", "ETrade", "restdump_{0:yyyyMMdd-HHmmss}.log".Put(DateTime.Now)); _logManager.Listeners.Add(new FileLogListener(path)); Application.Current.MainWindow = this; }
public LogControlPanel() { Content = _logControl; _listener = new GuiLogListener(_logControl); WhenLoaded(() => new AddLogListenerCommand(_listener).SyncProcess(this)); }
public LogManagerPanel() { Content = _monitor; _listener = new GuiLogListener(_monitor); // загрузка контрола происходит только при открытии окна актипро // если окно свернуто, то событие загрузки не вызывается. ConfigManager.GetService<LogManager>().Listeners.Add(_listener); //Loaded += OnLoaded; }
public MainWindow() { InitializeComponent(); Instance = this; _securitiesWindow.MakeHideable(); _ordersWindow.MakeHideable(); _stopOrdersWindow.MakeHideable(); _portfoliosWindow.MakeHideable(); _myTradesWindow.MakeHideable(); var guilistener = new GuiLogListener(LogControl); //guilistener.Filters.Add(msg => msg.Level > LogLevels.Debug); _logManager.Listeners.Add(guilistener); _logManager.Listeners.Add(new FileLogListener("rithmic") { LogDirectory = "Logs" }); }
public MainWindow() { Instance = this; InitializeComponent(); Closing += OnClosing; _ordersWindow.MakeHideable(); _securitiesWindow.MakeHideable(); _stopOrdersWindow.MakeHideable(); _portfoliosWindow.MakeHideable(); var guiListener = new GuiLogListener(LogControl); //guiListener.Filters.Add(msg => msg.Level > LogLevels.Debug); _logManager.Listeners.Add(guiListener); _logManager.Listeners.Add(new FileLogListener("sterling") { LogDirectory = "Logs" }); Application.Current.MainWindow = this; }