Ejemplo n.º 1
0
        /// <summary>
        /// Create a new instance of the FolderBrowserDialog
        /// </summary>
        public FolderBrowserForm(MainControler mainControler)
        {
            //
            // TODO: Add constructor logic here
            //
            InitializeComponent();

            //add folder images to imagelist
            if (mainControler.DisplayResolution == DisplayResolution.VGA)
            {
                this.ilIcons.ImageSize = new System.Drawing.Size(32, 32);
            }

            ilIcons.Images.Add(ToolbarMaker.GetIconFromFile(mainControler.Config.ApplicationDirectory + @"\Icons\Folder"));
            //ilIcons.Images.Add(new System.Drawing.Bitmap(System.Reflection.Assembly.GetExecutingAssembly().GetManifestResourceStream("OpenNETCF.Windows.Forms.Images.Device.gif")));
            //ilIcons.Images.Add(new System.Drawing.Bitmap(System.Reflection.Assembly.GetExecutingAssembly().GetManifestResourceStream("OpenNETCF.Windows.Forms.Images.Card.gif")));

            //set default image index to 0
            tvFolders.ImageIndex         = 0;
            tvFolders.SelectedImageIndex = 0;

            //use a backslash between path levels
            tvFolders.PathSeparator = "\\";

            //setup default tree
            Reset();
        }
Ejemplo n.º 2
0
        public IDialog() : base()
        {
            // Button
            resultButton = new ResultButton();
            this.Controls.Add(resultButton);

            this.toolBar        = new System.Windows.Forms.ToolBar();
            this.tbOkButton     = new System.Windows.Forms.ToolBarButton();
            this.tbCancelButton = new System.Windows.Forms.ToolBarButton();

            //
            // toolBar
            //
            this.toolBar.Buttons.Add(this.tbOkButton);
            this.toolBar.Buttons.Add(this.tbCancelButton);
            this.toolBar.Name         = "toolBar";
            this.toolBar.ButtonClick += new System.Windows.Forms.ToolBarButtonClickEventHandler(this.toolBar_ButtonClick);

            this.Controls.Add(this.toolBar);

            // Toolbar
            string appPath = System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().GetModules()[0].FullyQualifiedName);

            ToolbarMaker.ToolBar = toolBar;
            ToolbarMaker.AddIcon(appPath + @"\Icons\tbOk");
            ToolbarMaker.AddIcon(appPath + @"\Icons\tbCancel");


            this.TopMost = true;
        }
Ejemplo n.º 3
0
        public MapServerSettings(Rectangle visibleRect, MainControler mainControler)
            : this()
        {
            this.config = mainControler.Config;

            this.tbUpdateData = new System.Windows.Forms.ToolBarButton();
            this.toolBar.Buttons.Add(this.tbUpdateData);
            ToolbarMaker.AddIcon(config.ApplicationDirectory + @"\Icons\update");

            this.Location               = new System.Drawing.Point(0, visibleRect.Y);
            this.ClientSize             = new System.Drawing.Size(visibleRect.Width, visibleRect.Height);
            this.layerTabControl.Height = this.ClientSize.Height - Caption.Height - 3;
            this.panel1.Height          = layerTabControl.Height;
            this.mainControler          = mainControler;
            this.config = mainControler.Config;
            this.availLayersView.ContextMenu = new MsLayerMenu(this);
        }