Exemple #1
0
        public TabNavigationForm(WorkbenchForm mainForm)
        {
            this._mainForm  = mainForm;
            this.Owner      = mainForm;
            this.KeyPreview = true;
            InitializeComponent();

            listViewPad.SmallImageList  = new ImageList();
            listViewFile.SmallImageList = new ImageList();

            ///添加Pad工具栏
            ListViewItem itemProperty = new ListViewItem(_mainForm.MainPropertyPad.Text);

            itemProperty.Tag = _mainForm.MainPropertyPad;
            listViewPad.SmallImageList.Images.Add(_mainForm.MainPropertyPad.Icon.Handle.ToString(),
                                                  _mainForm.MainPropertyPad.Icon);
            itemProperty.ImageKey = _mainForm.MainPropertyPad.Icon.Handle.ToString();

            ListViewItem itemTree = new ListViewItem(_mainForm.MainStonePad.Text);

            itemTree.Tag = _mainForm.MainStonePad;
            listViewPad.SmallImageList.Images.Add(_mainForm.MainStonePad.Icon.Handle.ToString(),
                                                  _mainForm.MainStonePad.Icon);
            itemTree.ImageKey = _mainForm.MainStonePad.Icon.Handle.ToString();

            this.listViewPad.Items.Add(itemProperty);
            this.listViewPad.Items.Add(itemTree);
        }
Exemple #2
0
 /// <summary>
 /// 初始化窗体,一般在程序启动时初始化
 /// </summary>
 /// <param name="args"></param>
 static internal void Initialize(string[] args)
 {
     CommandLineArgs = args;
     MainForm        = new WorkbenchForm();
     OnWorkbenchCreated();
     if (Initialized != null)
     {
         Initialized(null, EventArgs.Empty);
     }
 }
Exemple #3
0
        public WordsManager(WorkbenchForm mainForm)
        {
            ThreadNum   = 4;
            GetedPage   = 0;
            TotalPages  = 0;
            ProgressBar = null;

            FailedUrls = new List <string>();
            GetedUrls  = new List <string>();
            NewWords   = new Dictionary <string, ulong>();
            ExistWords = new Dictionary <string, ulong>();
            MainForm   = mainForm;
        }
Exemple #4
0
        static void Main(string[] args)
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            ///初始化WorkbenchForm窗体,保存传入参数,这可能是双击某文件,
            ///产生的关联启动了本程序,那么参数就是文件路径
            WorkbenchForm.Initialize(args);

            InitializeApplication.Initialize();

            Application.Run(WorkbenchForm.MainForm);
        }
Exemple #5
0
 public WordsManager(WorkbenchForm mainForm)
 {
     NewWords   = new Dictionary <string, ulong>();
     ExistWords = new Dictionary <string, ulong>();
     _mainForm  = mainForm;
 }
Exemple #6
0
 /// <summary>
 ///  构造函数
 /// </summary>
 public UrlManager(WorkbenchForm mainForm)
 {
     _mainForm = mainForm;
     Urls      = new List <UrlItem>();
 }