Exemplo n.º 1
0
        private void MetroWindow_Closed(object sender, EventArgs e)
        {
            _remoteControl?.Release();
            _fullScreenWindow?.Close();
            OnRemove?.Invoke(this, new EventArgs());
            Window mainWindow = Application.Current.MainWindow;

            if (mainWindow != null)
            {
                _itemRemoteLink.ExternalWindowWidth  = mainWindow.Width == Width ? 0 : Width;
                _itemRemoteLink.ExternalWindowHeight = mainWindow.Height == Height ? 0 : Height;
            }
            Database.Update(_itemRemoteLink.Id, _itemRemoteLink);
        }
Exemplo n.º 2
0
        private void Button_ConnectBar_Click(object sender, RoutedEventArgs e)
        {
            Button button = sender as Button;

            if (button == null)
            {
                return;
            }
            if (button.Name == "PART_Close")
            {
                _fullScreenWindow.Close();
                Close();
            }
            if (button.Name == "PART_Resize")
            {
                FullScreen(false);
            }
            if (button.Name == "PART_Min")
            {
                _fullScreenWindow.WindowState = WindowState.Minimized;
            }
        }
Exemplo n.º 3
0
 private void _tabItem_Closed(object sender)
 {
     _remoteControl?.Release();
     _fullScreenWindow?.Close();
     OnRemove?.Invoke(this, new EventArgs());
 }