public virtual void AddListPrevButton( int x, int y, bool valid, GumpResponse response )
 {
     if ( valid )
         AddButton( x, y, PrevNormalID, PrevPressedID, response );
     else
         AddImage( x, y, PrevDisabledID );
 }
        public GumpImageTileButton(
            int x,
            int y,
            int normalID,
            int pressedID,
            int buttonID,
            GumpButtonType type,
            int param,
            int itemID,
            int hue,
            int width,
            int height,
            GumpResponse callback,
            int localizedTooltip,
            string name)
        {
            _X       = x;
            _Y       = y;
            _ID1     = normalID;
            _ID2     = pressedID;
            _EntryID = buttonID;
            _Type    = type;
            _Param   = param;

            _ItemID = itemID;
            _Hue    = hue;
            _Width  = width;
            _Height = height;

            _LocalizedTooltip = localizedTooltip;

            _Callback = callback;
            _Name     = (name != null ? name : "");
        }
        public CustomServiceGumpling(Int32 width, Int32 height, Int32 coreLabelHue, String coreLabel, String version, GumpResponse saveButtonPressed) : base(0, 0)
        {
            Bitmap text = OpenUOSDK.AsciiFontFactory.GetText<Bitmap>(1, coreLabel, 0);

            Add(new StoneyBackground(width, height));
            Add(new GumpLabel((width - text.Width) / 2, 4, coreLabelHue, coreLabel));
            Add(new GumpImageTiled(2, 30, width - 4, 4, 0x13ED));
            Add(new GumpLabel(10, height - 25, 0x4B, String.Format("v{0}", version)));
            Add(new SaveCancelGumpling(width - 170, height - 30, saveButtonPressed));
        }
        public SaveCancelGumpling(Int32 x, Int32 y, GumpResponse saveCallback, GumpResponse cancelCallback) : base(x, y)
        {
            GumpButton button = new GumpButton(0, 0, 0x1452, 0x1453, -1, GumpButtonType.Reply, 0, saveCallback);
            button.OnGumpResponse += button_OnSave;
            Add(button);

            button = new GumpButton(85, 0, 0x1450, 0x1451, (cancelCallback == null ? 0 : -1), GumpButtonType.Reply, 0, cancelCallback);
            button.OnGumpResponse += button_OnCancel;
            Add(button);
        }
Exemple #5
0
 public GumpCheck(int x, int y, int inactiveID, int activeID, bool initialState, int switchID, GumpResponse callback, string name)
 {
     this._X            = x;
     this._Y            = y;
     this._ID1          = inactiveID;
     this._ID2          = activeID;
     this._InitialState = initialState;
     this._EntryID      = switchID;
     this._Name         = (name != null ? name : "");
     this._Callback     = callback;
 }
Exemple #6
0
 public GumpCheck(int x, int y, int inactiveID, int activeID, bool initialState, int switchID, GumpResponse callback, string name)
 {
     this._X = x;
     this._Y = y;
     this._ID1 = inactiveID;
     this._ID2 = activeID;
     this._InitialState = initialState;
     this._EntryID = switchID;
     this._Name = (name != null ? name : "");
     this._Callback = callback;
 }
Exemple #7
0
        public SaveCancelGumpling(Int32 x, Int32 y, GumpResponse saveCallback, GumpResponse cancelCallback) : base(x, y)
        {
            GumpButton button = new GumpButton(0, 0, 0x1452, 0x1453, -1, GumpButtonType.Reply, 0, saveCallback);

            button.OnGumpResponse += button_OnSave;
            Add(button);

            button = new GumpButton(85, 0, 0x1450, 0x1451, (cancelCallback == null ? 0 : -1), GumpButtonType.Reply, 0, cancelCallback);
            button.OnGumpResponse += button_OnCancel;
            Add(button);
        }
 public virtual void AddListNextButton(int x, int y, bool valid, GumpResponse response)
 {
     if (valid)
     {
         AddButton(x, y, NextNormalID, NextPressedID, response);
     }
     else
     {
         AddImage(x, y, NextDisabledID);
     }
 }
Exemple #9
0
        public ApplyCancelGumpling(Int32 x, Int32 y, GumpResponse applyCallback, GumpResponse cancelCallback) : base(x, y)
        {
            GumpButton button = new GumpButton(0, 0, 0x1454, 0x1455, -1, GumpButtonType.Reply, 0, applyCallback);

            button.OnGumpResponse += button_OnApply;
            Add(button);

            button = new GumpButton(85, 0, 0x1450, 0x1451, 0, GumpButtonType.Reply, 0, cancelCallback);
            button.OnGumpResponse += button_OnCancel;
            Add(button);
        }
Exemple #10
0
 public GumpTextEntry(int x, int y, int width, int height, int hue, int entryID, string initialText, GumpResponse callback, string name)
 {
     this._X = x;
     this._Y = y;
     this._Width = width;
     this._Height = height;
     this._Hue = hue;
     this._EntryID = entryID;
     this._InitialText = initialText;
     this._Callback = callback;
     this._Name = (name != null ? name : "");
 }
 public GumpTextEntry(int x, int y, int width, int height, int hue, int entryID, string initialText, GumpResponse callback, string name)
 {
     this._X           = x;
     this._Y           = y;
     this._Width       = width;
     this._Height      = height;
     this._Hue         = hue;
     this._EntryID     = entryID;
     this._InitialText = initialText;
     this._Callback    = callback;
     this._Name        = (name != null ? name : "");
 }
Exemple #12
0
 public GumpButton(int x, int y, int normalID, int pressedID, int buttonID, GumpButtonType type, int param, GumpResponse callback, string name)
 {
     this._X = x;
     this._Y = y;
     this._ID1 = normalID;
     this._ID2 = pressedID;
     this._EntryID = buttonID;
     this._Type = type;
     this._Param = param;
     this._Callback = callback;
     this._Name = (name != null ? name : "");
 }
Exemple #13
0
 public HyperLink(Point2D location, int hue, bool underlined, bool italicized, bool bold, GumpResponse callback, int callbackParam, string text, FontHandling.FontSize size = FontHandling.FontSize.Medium)
 {
     Location      = location;
     Hue           = hue;
     Underlined    = underlined;
     Italicized    = italicized;
     Bold          = bold;
     Callback      = callback;
     CallbackParam = callbackParam;
     Size          = size;
     DisplayText   = text;
 }
Exemple #14
0
 public GumpButton(int x, int y, int normalID, int pressedID, int buttonID, GumpButtonType type, int param, GumpResponse callback, string name)
 {
     this._X        = x;
     this._Y        = y;
     this._ID1      = normalID;
     this._ID2      = pressedID;
     this._EntryID  = buttonID;
     this._Type     = type;
     this._Param    = param;
     this._Callback = callback;
     this._Name     = (name != null ? name : "");
 }
 public GumpRadio(
     int x, int y, int inactiveID, int activeID, bool initialState, int switchID, GumpResponse callback, string name)
 {
     _X            = x;
     _Y            = y;
     _ID1          = inactiveID;
     _ID2          = activeID;
     _InitialState = initialState;
     _EntryID      = switchID;
     _Callback     = callback;
     _Name         = (name != null ? name : "");
 }
Exemple #16
0
		public GumpRadio(
			int x, int y, int inactiveID, int activeID, bool initialState, int switchID, GumpResponse callback, string name)
		{
			_X = x;
			_Y = y;
			_ID1 = inactiveID;
			_ID2 = activeID;
			_InitialState = initialState;
			_EntryID = switchID;
			_Callback = callback;
			_Name = (name != null ? name : "");
		}
        public CustomCoreGumpling(Int32 width, Int32 height, Int32 coreLabelHue, String coreLabel, Boolean coreEnabled, GumpResponse coreEnabledChanged, String version, GumpResponse saveButtonPressed) : base(0, 0)
        {
            Bitmap text = OpenUOSDK.AsciiFontFactory.GetText<Bitmap>(1, coreLabel, 0);

            Add(new StoneyBackground(width, height));
            Add(new GumpLabel((width - text.Width) / 2, 4, coreLabelHue, coreLabel));
            Add(new GumpLabel(10, 30, 0x54F, "Enabled"));
            Add(new GreyCheckbox(63, 25, "Core Enabled", coreEnabled, coreEnabledChanged));
            Add(new GumpImageTiled(2, 55, width - 4, 4, 0x13ED));
            Add(new GumpLabel(10, height - 25, 0x4B, String.Format("v{0}", version)));
            Add(new SaveCancelGumpling(width - 170, height - 30, saveButtonPressed));
        }
 public void AddTextEntry(
     int x,
     int y,
     int width,
     int height,
     int hue,
     int entryID,
     GumpResponse callback,
     string initialText = "",
     string name        = "")
 {
     Add(new GumpTextEntry(x, y, width, height, hue, entryID, initialText, callback, name));
 }
Exemple #19
0
		public void AddTextEntry(
			int x,
			int y,
			int width,
			int height,
			int hue,
			int entryID,
			GumpResponse callback,
			string initialText = "",
			string name = "")
		{
			Add(new GumpTextEntry(x, y, width, height, hue, entryID, initialText, callback, name));
		}
Exemple #20
0
        protected void Delta(ref GumpResponse var, GumpResponse val)
        {
            if (var == val)
            {
                return;
            }

            var = val;

            if (this.m_Parent != null)
            {
                this.m_Parent.Invalidate();
            }
        }
		public GumpImageTileButton(
			int x,
			int y,
			int normalID,
			int pressedID,
			GumpButtonType type,
			int param,
			int itemID,
			int hue,
			int width,
			int height,
			GumpResponse callback,
			string name)
			: this(x, y, normalID, pressedID, -1, type, param, itemID, hue, width, height, callback, -1, name)
		{ }
        public LabelAddRemoveGumpling(Int32 index, Int32 x, Int32 y, Int32 entryWidth, String entryName, Int32 entryHue, GumpResponse editCallback, GumpResponse removeCallback) : base(x, y)
        {
            _Index = index;

            Add(new GumpImageTiled(0, 0, entryWidth, 23, 0xA40));
            Add(new GumpImageTiled(1, 1, entryWidth - 2, 21, 0xBBC));
            Add(new GumpLabelCropped(5, 1, entryWidth - 10, 16, entryHue, entryName));

            GumpButton editButton = new GumpButton(entryWidth + 5, 0, 0xFBD, 0xFBF, -1, GumpButtonType.Reply, 0, editCallback);
            editButton.OnGumpResponse += editButton_OnGumpResponse;
            Add(editButton);

            GumpButton removeButton = new GumpButton(entryWidth + 35, 0, 0xFB4, 0xFB6, -1, GumpButtonType.Reply, 0, removeCallback);
            removeButton.OnGumpResponse += removeButton_OnGumpResponse;
            Add(removeButton);
        }
 public GumpImageTileButton(
     int x,
     int y,
     int normalID,
     int pressedID,
     GumpButtonType type,
     int param,
     int itemID,
     int hue,
     int width,
     int height,
     GumpResponse callback,
     string name)
     : this(x, y, normalID, pressedID, -1, type, param, itemID, hue, width, height, callback, -1, name)
 {
 }
 public GumpImageTileButton(
     int x,
     int y,
     int normalID,
     int pressedID,
     int buttonID,
     GumpButtonType type,
     int param,
     int itemID,
     int hue,
     int width,
     int height,
     GumpResponse callback,
     int localizedTooltip)
     : this(x, y, normalID, pressedID, buttonID, type, param, itemID, hue, width, height, callback, localizedTooltip, "")
 {
 }
Exemple #25
0
        public override void OnResponse(NetState sender, RelayInfo info)
        {
            int buttonid = info.ButtonID - 1;

            if (buttonid < 0 || buttonid > m_Responses.Count)
            {
                OnGumpCancelled(sender, info);
            }
            else
            {
                GumpResponse response  = m_Responses[buttonid];
                RelayInfo    localinfo = response.Section.LocalRelayInfo(info);
                if (response.Handler != null)
                {
                    response.Handler(sender, info, localinfo, response.LocalButtonID);
                }
                response.Section.OnResponse(sender, info, localinfo, response.LocalButtonID);
            }
        }
Exemple #26
0
        public GumpImageTileButton(int x, int y, int normalID, int pressedID, int buttonID, GumpButtonType type, int param, int itemID, int hue, int width, int height, GumpResponse callback, int localizedTooltip, string name)
        {
            this._X = x;
            this._Y = y;
            this._ID1 = normalID;
            this._ID2 = pressedID;
            this._EntryID = buttonID;
            this._Type = type;
            this._Param = param;

            this._ItemID = itemID;
            this._Hue = hue;
            this._Width = width;
            this._Height = height;

            this._LocalizedTooltip = localizedTooltip;

            this._Callback = callback;
            this._Name = (name != null ? name : "");
        }
		public GumpTextEntryLimited(
			int x,
			int y,
			int width,
			int height,
			int hue,
			int entryID,
			string initialText,
			int size,
			GumpResponse callback,
			string name)
		{
			_X = x;
			_Y = y;
			_Width = width;
			_Height = height;
			_Hue = hue;
			_EntryID = entryID;
			_InitialText = initialText;
			_Size = size;
			_Callback = callback;
			_Name = (name != null ? name : "");
		}
 public GumpTextEntryLimited(
     int x,
     int y,
     int width,
     int height,
     int hue,
     int entryID,
     string initialText,
     int size,
     GumpResponse callback,
     string name)
 {
     _X           = x;
     _Y           = y;
     _Width       = width;
     _Height      = height;
     _Hue         = hue;
     _EntryID     = entryID;
     _InitialText = initialText;
     _Size        = size;
     _Callback    = callback;
     _Name        = (name != null ? name : "");
 }
 public SaveCancelGumpling(Int32 x, Int32 y, GumpResponse saveCallback) : this(x, y, saveCallback, null) { }
		public virtual void AddButton( int x, int y, int normalID, int pressedID, int param, GumpResponse response )
		{
			AddButton( x, y, normalID, pressedID, GumpButtonType.Page, param, response );
		}
 public GreyCheckbox(Int32 x, Int32 y, String name, Boolean initialState, GumpResponse callback)
     : base(x, y, 0x25F8, 0x25FC, initialState, callback, name)
 {
 }
Exemple #32
0
 public HyperLink(Point2D location, int hue, bool underlined, bool italicized, bool bold, GumpResponse callback, int callbackParam, string text, FontHandling.FontSize size = FontHandling.FontSize.Medium)
 {
     Location = location;
     Hue = hue;
     Underlined = underlined;
     Italicized = italicized;
     Bold = bold;
     Callback = callback;
     CallbackParam = callbackParam;
     Size = size;
     DisplayText = text;
 }
		public GumpImageTileButton(
			int x,
			int y,
			int normalID,
			int pressedID,
			int buttonID,
			GumpButtonType type,
			int param,
			int itemID,
			int hue,
			int width,
			int height,
			GumpResponse callback,
			int localizedTooltip)
			: this(x, y, normalID, pressedID, buttonID, type, param, itemID, hue, width, height, callback, localizedTooltip, "")
		{ }
Exemple #34
0
		public GumpRadio(int x, int y, int inactiveID, int activeID, bool initialState, GumpResponse callback, string name)
			: this(x, y, inactiveID, activeID, initialState, -1, callback, name)
		{ }
Exemple #35
0
 public GumpCheck(int x, int y, int inactiveID, int activeID, bool initialState, GumpResponse callback, string name)
     : this(x, y, inactiveID, activeID, initialState, -1, callback, name)
 {
 }
 public GumpTextEntryLimited(
     int x, int y, int width, int height, int hue, int entryID, string initialText, int size, GumpResponse callback)
     : this(x, y, width, height, hue, entryID, initialText, size, callback, "")
 {
 }
 public GumpTextEntryLimited(
     int x, int y, int width, int height, int hue, string initialText, int size, GumpResponse callback, string name)
     : this(x, y, width, height, hue, -1, initialText, size, callback, name)
 {
 }
Exemple #38
0
 public GreyLeftArrow(Int32 x, Int32 y, GumpButtonType buttonType, Int32 param, GumpResponse callback) : base(x, y, 0x25EA, 0x25EB, -1, buttonType, param, callback)
 {
 }
Exemple #39
0
 public virtual void AddResponse(GumpResponse response)
 {
     m_Responses.Add(response);
 }
Exemple #40
0
		public GumpButton(
			int x, int y, int normalID, int pressedID, GumpButtonType type, int param, GumpResponse callback, string name)
			: this(x, y, normalID, pressedID, -1, type, param, callback, name)
		{ }
Exemple #41
0
 public virtual void AddButton(int x, int y, int normalID, int pressedID, GumpButtonType type, int param, GumpResponse response)
 {
     AddButton(x, y, normalID, pressedID, ++m_ButtonCount, type, param);
     AddResponse(response);
 }
Exemple #42
0
 public virtual void AddButton(int x, int y, int normalID, int pressedID, int param, GumpResponse response)
 {
     AddButton(x, y, normalID, pressedID, GumpButtonType.Page, param, response);
 }
Exemple #43
0
		public GumpRadio(int x, int y, int inactiveID, int activeID, bool initialState, int switchID, GumpResponse callback)
			: this(x, y, inactiveID, activeID, initialState, switchID, callback, "")
		{ }
		public GumpTextEntryLimited(
			int x, int y, int width, int height, int hue, string initialText, int size, GumpResponse callback, string name)
			: this(x, y, width, height, hue, -1, initialText, size, callback, name)
		{ }
Exemple #45
0
 public GumpCheck(int x, int y, int inactiveID, int activeID, bool initialState, int switchID, GumpResponse callback)
     : this(x, y, inactiveID, activeID, initialState, switchID, callback, "")
 {
 }
		public GumpTextEntryLimited(
			int x, int y, int width, int height, int hue, int entryID, string initialText, int size, GumpResponse callback)
			: this(x, y, width, height, hue, entryID, initialText, size, callback, "")
		{ }
		public virtual void AddImageTiledButton( int x, int y, int normalID, int pressedID, GumpButtonType type, int param, int itemID, int hue, int width, int height, int localizedTooltip, GumpResponse response )
		{
			m_RootParent.AddImageTiledButton( x + m_XOffset, y + m_YOffset, normalID, pressedID, type, param, itemID, hue, width, height, localizedTooltip, response );
			m_ButtonCount++;
		}
Exemple #48
0
 public GreyLeftArrow(Int32 x, Int32 y, GumpResponse callback) : this(x, y, GumpButtonType.Reply, 0, callback) { }
		public virtual void AddButton( int x, int y, int normalID, int pressedID, GumpButtonType type, int param, GumpResponse response )
		{
			m_RootParent.AddButton( x + m_XOffset, y + m_YOffset, normalID, pressedID, type, param, response );
			m_ButtonCount++;
		}
Exemple #50
0
 public GreyLeftArrow(Int32 x, Int32 y, GumpButtonType buttonType, Int32 param, GumpResponse callback) : base(x, y, 0x25EA, 0x25EB, -1, buttonType, param, callback) { }
Exemple #51
0
 public WebColoredHyperLink(Point2D location, string htmlColor, bool underlined, bool italicized, bool bold, GumpResponse callback, int callbackParam, string text, FontHandling.FontSize size = FontHandling.FontSize.Medium)
     : base(location, 0, underlined, italicized, bold, callback, callbackParam, text, size)
 {
     HtmlColor = htmlColor;
 }
Exemple #52
0
 public GumpButton(int x, int y, int normalID, int pressedID, GumpButtonType type, int param, GumpResponse callback, string name)
     : this(x, y, normalID, pressedID, -1, type, param, callback, name)
 {
 }
Exemple #53
0
 public void AddRadio(
     int x, int y, int inactiveID, int activeID, bool initialState, GumpResponse callback, string name = "")
 {
     Add(new GumpRadio(x, y, inactiveID, activeID, initialState, NewID(), callback, name));
 }
Exemple #54
0
 public GumpButton(int x, int y, int normalID, int pressedID, int buttonID, GumpButtonType type, int param, GumpResponse callback)
     : this(x, y, normalID, pressedID, buttonID, type, param, callback, "")
 {
 }
Exemple #55
0
		public void AddTextEntry(
			int x, int y, int width, int height, int hue, string initialText, int size, GumpResponse callback, string name = "")
		{
			Add(new GumpTextEntryLimited(x, y, width, height, hue, NewID(), initialText, size, callback, name));
		}
Exemple #56
0
 public GreyLeftArrow(Int32 x, Int32 y, GumpResponse callback) : this(x, y, GumpButtonType.Reply, 0, callback)
 {
 }
Exemple #57
0
 public virtual void AddImageTiledButton(int x, int y, int normalID, int pressedID, GumpButtonType type, int param, int itemID, int hue, int width, int height, int localizedTooltip, GumpResponse response)
 {
     AddImageTiledButton(x, y, normalID, pressedID, ++m_ButtonCount, type, param, itemID, hue, width, height, localizedTooltip);
     AddResponse(response);
 }
Exemple #58
0
 public virtual void AddButton(int x, int y, int normalID, int pressedID, GumpResponse response)
 {
     AddButton(x, y, normalID, pressedID, GumpButtonType.Reply, 0, response);
 }
Exemple #59
0
		public GumpButton(
			int x, int y, int normalID, int pressedID, int buttonID, GumpButtonType type, int param, GumpResponse callback)
			: this(x, y, normalID, pressedID, buttonID, type, param, callback, "")
		{ }
 public ElementProperty(string display, GumpResponse callback, string text, InputType elementInputType, bool isChecked = false, UpdateString bookTextCallback = null)
 {
     Display = display;
     Callback = callback;
     Text = text;
     ElementInputType = elementInputType;
     Checked = isChecked;
     BookCallback = bookTextCallback;
 }