Inheritance: System.Windows.Forms.UserControl
Exemplo n.º 1
0
        private void Search_Graphic(object sender, EventArgs e)
        {
            int graphic;

            if (Utils.ConvertStringToInt(textBoxGraphic.Text, out graphic, 0, Art.StaticLength - 1))
            {
                bool res;
                if (Options.DesignAlternative)
                {
                    res = ItemShowAlternative.SearchGraphic(graphic);
                }
                else
                {
                    res = ItemShow.SearchGraphic(graphic);
                }
                if (!res)
                {
                    DialogResult result = MessageBox.Show("No item found", "Result",
                                                          MessageBoxButtons.OKCancel, MessageBoxIcon.Error, MessageBoxDefaultButton.Button2);
                    if (result == DialogResult.Cancel)
                    {
                        Close();
                    }
                }
            }
        }
 public ItemShowAlternative()
 {
     InitializeComponent();
     SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.OptimizedDoubleBuffer | ControlStyles.UserPaint, true);
     refMarker = this;
     pictureBox.MouseWheel += new MouseEventHandler(OnMouseWheel);
 }
Exemplo n.º 3
0
        private void SearchNextName(object sender, EventArgs e)
        {
            bool res;

            if (Options.DesignAlternative)
            {
                res = ItemShowAlternative.SearchName(textBoxItemName.Text, true);
            }
            else
            {
                res = ItemShow.SearchName(textBoxItemName.Text, true);
            }
            if (!res)
            {
                DialogResult result = MessageBox.Show("No item found", "Result",
                                                      MessageBoxButtons.OKCancel, MessageBoxIcon.Error, MessageBoxDefaultButton.Button2);
                if (result == DialogResult.Cancel)
                {
                    Close();
                }
            }
        }