Exemplo n.º 1
0
        public virtual void FindInfo(ObjectListView olv)
        {
            FilterForm ff = FilterForm.GetInstance(olv);

            if (!ff.Created || !ff.Visible)
            {
                ff.Show();
            }
            else
            {
                ff.Activate();
            }
        }
Exemplo n.º 2
0
        private bool StartPlay(IGameFile gameFile, ISourcePortData sourcePort, bool screenFilter)
        {
            GameFilePlayAdapter playAdapter = CreatePlayAdapter(m_currentPlayForm, playAdapter_ProcessExited, AppConfiguration);

            m_saveGames = new IFileData[] { };

            if (AppConfiguration.CopySaveFiles)
            {
                CopySaveGames(gameFile, sourcePort);
            }
            CreateFileDetectors(sourcePort);

            if (m_currentPlayForm.PreviewLaunchParameters)
            {
                ShowLaunchParameters(playAdapter, gameFile, sourcePort);
            }

            bool isGameFileIwad = IsGameFileIwad(gameFile);

            if (m_currentPlayForm.SaveStatistics)
            {
                SetupStatsReader(sourcePort, gameFile);
            }

            if (playAdapter.Launch(AppConfiguration.GameFileDirectory, AppConfiguration.TempDirectory,
                                   gameFile, sourcePort, isGameFileIwad))
            {
                m_currentPlayFile = gameFile;

                if (gameFile != null)
                {
                    gameFile.LastPlayed = DateTime.Now;
                    m_dtStartPlay       = DateTime.Now;
                    DataSourceAdapter.UpdateGameFile(gameFile, new GameFileFieldType[] { GameFileFieldType.LastPlayed });
                    UpdateDataSourceViews(gameFile);
                }
            }
            else
            {
                MessageBox.Show(this, playAdapter.LastError, "Launch Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                return(false);
            }

            if (screenFilter)
            {
                m_filterForm = new FilterForm(Screen.FromControl(this), m_currentPlayForm.GetFilterSettings());
                m_filterForm.Show(this);
            }

            return(true);
        }
Exemplo n.º 3
0
 private void FilterButton_Click(object sender, EventArgs e)
 {
     if (filterForm == null)
     {
         filterForm = new FilterForm(this);
     }
     else
     {
         filterForm.BringToFront();
         filterForm.FilterForm_Load(sender, e);
     }
     this.Enabled = false;
     filterForm.Show();
     //comboBox1.Items.Add("lul");
     //comboBox1.Items.Add("kek");
     //comboBox1.Items.Add("aru");
 }
Exemplo n.º 4
0
        public PluginControl()
        {
            InitializeComponent();

            var allItems = new AllItems();

            dockPanel1.Theme = new VS2015LightTheme();

            filterForm = new FilterForm(allItems);
            filterForm.Show(dockPanel1, DockState.DockLeft);
            filterForm.FilterChanged += FilterForm_FilterChanged;

            detailsForm = new DetailsForm();
            detailsForm.Show(dockPanel1, DockState.DockBottom);

            traceForm = new TraceForm(allItems);
            traceForm.Show(dockPanel1, DockState.Document);
            traceForm.TraceSelected += TraceForm_TraceSelected;
        }
Exemplo n.º 5
0
        private void showFilterFormToolStripMenuItem_Click(object sender, EventArgs e)
        {
            var filterForm = new FilterForm();

            filterForm.Show();
        }
 public override void Run()
 {
     FilterForm form =  new FilterForm { BackColor = Color.Aqua };
     form.Show();
 }
Exemplo n.º 7
0
 private void FilterFormCreate()
 {
     filterForm          = new FilterForm(_dataGridView);
     filterForm.Location = new Point(0, Parent.Location.Y + button1.Size.Height + _dataGridView.ColumnHeadersHeight);
     filterForm.Show();
 }
Exemplo n.º 8
0
        /// <summary>
        /// Отваря прозореца за създаване на филтъра на търсене на филм / сериал
        /// </summary>
        private void filters_Click(object sender, EventArgs e)
        {
            FilterForm filter = new FilterForm();

            filter.Show();
        }
Exemplo n.º 9
0
        private void button1_Click(object sender, EventArgs e)
        {
            FilterForm filterForm = new FilterForm(_audio);

            filterForm.Show();
        }
Exemplo n.º 10
0
        private void button10_Click(object sender, EventArgs e)
        {
            try
            {
                FilterFormTemplate <ShapeColumnTemplate> fft = TemplateLoader.LoadTemplateFromJsonFile <FilterFormTemplate <ShapeColumnTemplate> >("./Templates/FilterFormTest1.json");

                bool show = false;

                if (null == ff)
                {
                    ff   = new FilterForm();
                    show = true;

                    ff.SaveItemsCallback = (s, list) =>
                    {
                    };

                    ff.MenuItemResolver = (entity, command) =>
                    {
                        var item = entity as Row;

                        if (null == item)
                        {
                            return(false);
                        }

                        if (command.Equals("Menu1"))
                        {
                            return(false);
                        }

                        return(true);
                    };

                    ff.WorkCallback += objects =>
                    {
                        Thread.Sleep(1000);

                        List <GridRowContent> list = new List <GridRowContent>();
                        list.Add(new GridRowContent("tset1", new Row {
                            Column1 = "tset1", Column2 = "test2"
                        }));
                        list.Add(new GridRowContent("tset2", new Row {
                            Column1 = "tset2", Column2 = "test2"
                        }));
                        list.Add(new GridRowContent("tset3", new Row {
                            Column1 = "tset3", Column2 = "test2"
                        }));

                        return(new FilterFormContent()
                        {
                            ScreenContent = new FilterScreenContent()
                            {
                                RowContentList = list,
                                ChartPoints = new List <ChartPoint>()
                                {
                                    new ChartPoint("test1", 10),
                                    new ChartPoint("test2", 20),
                                }
                            },
                            LabelValues = new List <string>()
                            {
                                "test1",
                                "test2"
                            }
                        });
                    };
                }

                ff.ApplyTemplate(fft);

                if (show)
                {
                    ff.Show(this);
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.ToString());
            }
        }