Ejemplo n.º 1
0
        private void UpdateUI()
        {
            dataGridView1.DataSource = null;

            lvListing.SetWindowTheme("explorer");
            lvListing.VirtualListSize = 0;
            viewModel = null;
            if (document == null)
            {
                return;
            }

            // Listen to navigation events.
            document.Navigator.LocationChanged += navigator_LocationChanged;

            // Create the view model.
            viewModel = new ListingViewModel(document.Image);
            //dataGridView1.Columns.Clear();
            dataGridView1.AutoGenerateColumns = false;
            dataGridView1.Font       = new System.Drawing.Font(FontFamily.GenericMonospace, this.Font.Size);
            dataGridView1.DataSource = null;
            dataGridView1.DataSource = viewModel.Rows;
            dataGridView1.Refresh();

            // Fill the procedure window.
            cbProcedures.Items.Clear();
            cbProcedures.Items.AddRange(viewModel.ProcedureItems.ToArray());

            // Fill the segment window.
            cbSegments.Items.Clear();
            cbSegments.Items.AddRange(viewModel.SegmentItems.ToArray());

            // Display the listing rows.
            //scope = ListingScope.Procedure;
            scope = ListingScope.Executable; // should rename to Image
            UpdateScope();
        }
Ejemplo n.º 2
0
        private void UpdateUI()
        {
            dataGridView1.DataSource = null;

            lvListing.SetWindowTheme("explorer");
            lvListing.VirtualListSize = 0;
            viewModel = null;
            if (document == null)
                return;

            // Listen to navigation events.
            document.Navigator.LocationChanged += navigator_LocationChanged;

            // Create the view model.
            viewModel = new ListingViewModel(document.Image);
            //dataGridView1.Columns.Clear();
            dataGridView1.AutoGenerateColumns = false;
            dataGridView1.Font = new System.Drawing.Font(FontFamily.GenericMonospace, this.Font.Size);
            dataGridView1.DataSource = null;
            dataGridView1.DataSource = viewModel.Rows;
            dataGridView1.Refresh();

            // Fill the procedure window.
            cbProcedures.Items.Clear();
            cbProcedures.Items.AddRange(viewModel.ProcedureItems.ToArray());

            // Fill the segment window.
            cbSegments.Items.Clear();
            cbSegments.Items.AddRange(viewModel.SegmentItems.ToArray());

            // Display the listing rows.
            //scope = ListingScope.Procedure;
            scope = ListingScope.Executable; // should rename to Image
            UpdateScope();
        }
Ejemplo n.º 3
0
 private void mnuScopeSegment_Click(object sender, EventArgs e)
 {
     this.ListingScope = ListingScope.Segment;
 }
Ejemplo n.º 4
0
 private void mnuScopeProcedure_Click(object sender, EventArgs e)
 {
     this.ListingScope = ListingScope.Procedure;
 }
Ejemplo n.º 5
0
 private void mnuScopeExecutable_Click(object sender, EventArgs e)
 {
     this.ListingScope = ListingScope.Executable;
 }