예제 #1
0
        private void Irrigation_MouseUp(object sender, MouseButtonEventArgs e)
        {
            var x = alldatabases.Width;

            mainGrid.Children.Remove(alldatabases);
            alldatabases                 = new AllDataBases("Irrigation");
            alldatabases.Width           = x;
            alldatabases.mainGrid.Width  = x;
            alldatabases.Operation.Width = x;
            alldatabases.Visibility      = Visibility.Visible;
            mainGrid.Children.Add(alldatabases);
        }
예제 #2
0
 public MainWindow()
 {
     InitializeComponent();
     alldatabases            = new AllDataBases("Pesticides");
     alldatabases.Visibility = Visibility.Hidden;
     mainGrid.Children.Add(alldatabases);
     timer          = new DispatcherTimer();
     timer.Interval = TimeSpan.Zero;
     timer.Tick    += timer_Tick;
     alldatabases.IsVisibleChanged += alldatabases_IsVisibleChanged;
     // hado ghadi ikono fkol forms
     #region :myStaticForm
     this.MouseDown            += MainWindow_MouseDown;
     this.WindowStartupLocation = WindowStartupLocation.CenterScreen;
     this.ResizeMode            = ResizeMode.NoResize;
 }