Ejemplo n.º 1
0
        public void RefreshStatus()
        {
            if (FilteringSystem.IsScheduelActive())
            {
                if (FIlterScheduelingSystem.isBlockdAt(DateTime.Now))
                {
                    statusLabel.Text      = "חסימה מתוזמנת";
                    statusLabel.ForeColor = Color.Red;

                    //Block the Internt using the service
                    ServiceAdapter.StartInternetBlocking();
                }
                else
                {
                    statusLabel.Text      = "גלישה מאופשרת";
                    statusLabel.ForeColor = Color.LimeGreen;

                    //release service's internet blocking
                    ServiceAdapter.StopInterntBlocking();
                }
            }
            else
            {
                statusLabel.Text      = "לא פעיל";
                statusLabel.ForeColor = Color.Red;
                ServiceAdapter.StopInterntBlocking();
            }
        }
Ejemplo n.º 2
0
 public Schedule()
 {
     InitializeComponent();
     FontSetup();
     FIlterScheduelingSystem.LoadSavedTable();
     FIlterScheduelingSystem.drawTable(40, 20, 10, 10);
     schedulePanel.Controls.Add(FIlterScheduelingSystem.getTable());
     scheduleBlockChecker_Tick(null, null);
 }
Ejemplo n.º 3
0
        private void saveChangsButton_Click(object sender, EventArgs e)
        {
            //Save changes in the schedueling table.
            FIlterScheduelingSystem.SaveTable();

            MessageBox.Show("השינויים נשמרו בהצלחה!", "לוקחים אחריות", MessageBoxButtons.OK, MessageBoxIcon.Information);

            //Refresh for current status
            RefreshStatus();
        }