示例#1
0
		public frmSpriteEditor(PluginBase plugin, List<string> pluginArgs)
			: base(plugin, pluginArgs) {
			InitializeComponent();

			mWndSprite = new FrameWindow {
				RightToLeftLayout = RightToLeftLayout,
				AllowDrop = true
			};
			mWndSprite.DragEnter += frmSpriteEditor_DragEnter;
			mWndSprite.DragDrop += frmSpriteEditor_DragDrop;
			mWndPalette = new PaletteWindow {
				RightToLeftLayout = RightToLeftLayout
			};

			if (MenuPaletteColorHighlight.ColorComboBox.SelectedIndex == 1)
				MenuPaletteColorHighlight.ColorComboBox.SelectedIndex = 0;
			MenuPaletteColorHighlight.ColorComboBox.SelectedIndex = 1;
			MouseWheel += new MouseEventHandler(frmSpriteEditor_MouseWheel);

			if (pluginArgs != null && pluginArgs.Count > 0) {
				ParsePluginArgs(pluginArgs);
			}
		}
示例#2
0
 public frmPluginPage(PluginBase plugin, List <string> PluginArgs)
     : this()
 {
     Plugin = plugin;
     InitializeComponent();
 }
示例#3
0
		public frmPluginPage(PluginBase plugin, List<string> PluginArgs)
			: this() {
			Plugin = plugin;
			InitializeComponent();
		}
示例#4
0
		private void AddPluginButton(PluginBase p) {
			var offsetX = (pnlPlugins.Controls.Count % 3) * 16; // 3 per row
			var offsetY = (pnlPlugins.Controls.Count / 3) * 16;
			var btn = new ButtonPlugin(p);
			offsetX += (pnlPlugins.Controls.Count % 3) * btn.Width;
			offsetY += (pnlPlugins.Controls.Count / 3) * btn.Height;
			btn.Location = new Point(offsetX, offsetY);
			btn.Click += ButtonPlugin_Click;

			pnlPlugins.Controls.Add(btn);
		}