Esempio n. 1
0
 private void tsbAddImageToLibrary(object sender, EventArgs e)
 {
     if (listBoxImages.SelectedIndex >= 0 && listBoxImages.SelectedIndex < listBoxImages.Items.Count)
     {
         MNReferencedImage ri = (MNReferencedImage)listBoxImages.Items[listBoxImages.SelectedIndex];
         if (ri != null)
         {
             MNSharedObjects.AddImage(ri);
             MNSharedObjects.Save();
         }
     }
 }
Esempio n. 2
0
        private void tsbAddStyleToLibrary(object sender, EventArgs e)
        {
            ListBox lb = listBoxStyles;

            if (lb.SelectedIndex >= 0 && lb.SelectedIndex < lb.Items.Count)
            {
                MNReferencedStyle selectedStyle = lb.Items[lb.SelectedIndex] as MNReferencedStyle;
                if (selectedStyle != null)
                {
                    MNSharedObjects.AddStyle(selectedStyle);
                    MNSharedObjects.Save();
                }
            }
        }
Esempio n. 3
0
        public MainFrame()
        {
            InitializeComponent();

            MNSharedObjects.Load();

            pageDetailPanel1.Dock    = DockStyle.Fill;
            pageDetailPanel1.Visible = true;
            pageDetailPanel1.SetSharedDocument();

            MNNotificationCenter.CreateNewDocument();
            autoSave          = new Timer();
            autoSave.Interval = 900000;
            autoSave.Tick    += new EventHandler(autoSave_Tick);
            autoSave.Start();

            ViewForm.Shared.Show();
        }