Merge with develop

This commit is contained in:
Nimetu 2016-03-01 22:39:10 +02:00
commit beadf6657b
7 changed files with 562 additions and 14 deletions

View file

@ -34,6 +34,7 @@ namespace NLGUI
class CCtrlButton;
class CCtrlScroll;
class CGroupList;
class CGroupMenu;
class CDBGroupComboBox;
class CGroupParagraph;
@ -189,6 +190,7 @@ namespace NLGUI
std::string DefaultFormTextGroup;
std::string DefaultFormTextAreaGroup;
std::string DefaultFormSelectGroup;
std::string DefaultFormSelectBoxMenuGroup;
std::string DefaultCheckBoxBitmapNormal;
std::string DefaultCheckBoxBitmapPushed;
std::string DefaultCheckBoxBitmapOver;
@ -345,6 +347,7 @@ namespace NLGUI
// Add a combo box in the current paragraph
CDBGroupComboBox *addComboBox(const std::string &templateName, const char *name);
CGroupMenu *addSelectBox(const std::string &templateName, const char *name);
// Add a button in the current paragraph. actionHandler, actionHandlerParams and tooltip can be NULL.
CCtrlButton *addButton(CCtrlButton::EType type, const std::string &name, const std::string &normalBitmap, const std::string &pushedBitmap,
@ -409,6 +412,10 @@ namespace NLGUI
double _TimeoutValue; // the timeout in seconds
double _ConnectingTimeout;
sint _RedirectsRemaining;
// Automatic page refresh
double _LastRefreshTime;
double _NextRefreshTime;
std::string _RefreshUrl;
// minimal embeded lua script support
// Note : any embeded script is executed immediately after the closing
@ -626,6 +633,10 @@ namespace NLGUI
TextArea = NULL;
Checkbox = NULL;
ComboBox = NULL;
SelectBox = NULL;
sbRBRef = NULL;
sbMultiple = false;
sbOptionDisabled = -1;
InitialSelection = 0;
}
@ -644,6 +655,19 @@ namespace NLGUI
// Combobox group
CDBGroupComboBox *ComboBox;
// Combobox with multiple selection or display size >= 2
CGroupMenu *SelectBox;
// Single or multiple selections for SelectBox
bool sbMultiple;
// Marks OPTION element as disabled
// Only valid when parsing html
sint sbOptionDisabled;
// First radio button in SelectBox if single selection
CCtrlBaseButton *sbRBRef;
// select values (for the <select> tag)
std::vector<std::string> SelectValues;
sint InitialSelection; // initial selection for the combo box

View file

@ -346,6 +346,7 @@ namespace NLGUI
// set the minW of the RootMenu.
void setMinW(sint32 minW);
void setMinH(sint32 minH);
// Gray a line on the RootMenu
void setGrayedLine(uint line, bool g);

View file

@ -26,6 +26,7 @@
#include "nel/gui/libwww.h"
#include "nel/gui/group_html.h"
#include "nel/gui/group_list.h"
#include "nel/gui/group_menu.h"
#include "nel/gui/group_container.h"
#include "nel/gui/view_link.h"
#include "nel/gui/ctrl_scroll.h"
@ -1137,6 +1138,40 @@ namespace NLGUI
}
}
break;
case HTML_META:
if (_ReadingHeadTag)
{
bool httpEquiv = present[HTML_META_HTTP_EQUIV] && value[HTML_META_HTTP_EQUIV];
bool httpContent = present[HTML_META_CONTENT] && value[HTML_META_CONTENT];
if (httpEquiv && httpContent)
{
// only first http-equiv="refresh" should be handled
if (_RefreshUrl.empty() && toLower(value[HTML_META_HTTP_EQUIV]) == "refresh")
{
const CWidgetManager::SInterfaceTimes &times = CWidgetManager::getInstance()->getInterfaceTimes();
double timeSec = times.thisFrameMs / 1000.0f;
string content(value[HTML_META_CONTENT]);
string::size_type pos = content.find_first_of(";");
if (pos == string::npos)
{
fromString(content, _NextRefreshTime);
_RefreshUrl = _URL;
}
else
{
fromString(content.substr(0, pos), _NextRefreshTime);
pos = toLower(content).find("url=");
if (pos != string::npos)
_RefreshUrl = content.substr(pos + 4);
}
_NextRefreshTime += timeSec;
}
}
}
break;
case HTML_A:
{
CStyleParams style;
@ -1691,15 +1726,50 @@ namespace NLGUI
case HTML_SELECT:
if (!(_Forms.empty()))
{
CStyleParams style;
// A select box
string name;
bool multiple = false;
sint32 size = 0;
if (present[HTML_SELECT_NAME] && value[HTML_SELECT_NAME])
name = value[HTML_SELECT_NAME];
if (present[HTML_SELECT_SIZE] && value[HTML_SELECT_SIZE])
fromString(value[HTML_SELECT_SIZE], size);
if (present[HTML_SELECT_MULTIPLE] && value[HTML_SELECT_MULTIPLE])
multiple = true;
if (present[HTML_SELECT_STYLE] && value[HTML_SELECT_STYLE])
getStyleParams(value[HTML_SELECT_STYLE], style);
CDBGroupComboBox *cb = addComboBox(DefaultFormSelectGroup, name.c_str());
CGroupHTML::CForm::CEntry entry;
entry.Name = name;
entry.sbMultiple = multiple;
if (size > 1 || multiple)
{
entry.InitialSelection = -1;
CGroupMenu *sb = addSelectBox(DefaultFormSelectBoxMenuGroup, name.c_str());
if (sb)
{
if (size < 1)
size = 4;
if (style.Width > -1)
sb->setMinW(style.Width);
if (style.Height > -1)
sb->setMinH(style.Height);
sb->setMaxVisibleLine(size);
}
entry.SelectBox = sb;
}
else
{
CDBGroupComboBox *cb = addComboBox(DefaultFormSelectGroup, name.c_str());
entry.ComboBox = cb;
}
_Forms.back().Entries.push_back (entry);
}
break;
@ -1713,17 +1783,14 @@ namespace NLGUI
_SelectOptionStr.clear();
std::string optionValue;
bool selected = false;
if (present[HTML_OPTION_VALUE] && value[HTML_OPTION_VALUE])
optionValue = value[HTML_OPTION_VALUE];
if (present[HTML_OPTION_SELECTED] && value[HTML_OPTION_SELECTED])
selected = nlstricmp(value[HTML_OPTION_SELECTED], "selected") == 0;
_Forms.back().Entries.back().SelectValues.push_back(optionValue);
if (selected)
{
_Forms.back().Entries.back().InitialSelection = (sint)_Forms.back().Entries.back().SelectValues.size() - 1;
}
if (present[HTML_OPTION_SELECTED])
_Forms.back().Entries.back().InitialSelection = (sint)_Forms.back().Entries.back().SelectValues.size() - 1;
if (present[HTML_OPTION_DISABLED])
_Forms.back().Entries.back().sbOptionDisabled = (sint)_Forms.back().Entries.back().SelectValues.size() - 1;
}
}
_SelectOption = true;
@ -2244,6 +2311,59 @@ namespace NLGUI
{
cb->addText(_SelectOptionStr);
}
else
{
CGroupMenu *sb = _Forms.back().Entries.back().SelectBox;
if (sb)
{
uint lineIndex = sb->getNumLine();
sb->addLine(_SelectOptionStr, "", "");
if (_Forms.back().Entries.back().sbOptionDisabled == lineIndex)
{
sb->setGrayedLine(lineIndex, true);
}
else
{
// create option line checkbox, CGroupMenu is taking ownership of the checbox
CInterfaceGroup *ig = CWidgetManager::getInstance()->getParser()->createGroupInstance("menu_checkbox", "", NULL, 0);
if (ig)
{
CCtrlButton *cb = dynamic_cast<CCtrlButton *>(ig->getCtrl("b"));
if (cb)
{
if (_Forms.back().Entries.back().sbMultiple)
{
cb->setType(CCtrlButton::ToggleButton);
cb->setTexture(DefaultCheckBoxBitmapNormal);
cb->setTexturePushed(DefaultCheckBoxBitmapPushed);
cb->setTextureOver(DefaultCheckBoxBitmapOver);
}
else
{
cb->setType(CCtrlButton::RadioButton);
cb->setTexture(DefaultRadioButtonBitmapNormal);
cb->setTexturePushed(DefaultRadioButtonBitmapPushed);
cb->setTextureOver(DefaultRadioButtonBitmapOver);
if (_Forms.back().Entries.back().sbRBRef == NULL)
_Forms.back().Entries.back().sbRBRef = cb;
cb->initRBRefFromRadioButton(_Forms.back().Entries.back().sbRBRef);
}
cb->setPushed(_Forms.back().Entries.back().InitialSelection == lineIndex);
sb->setUserGroupLeft(lineIndex, ig);
}
else
{
nlwarning("Failed to get 'b' element from 'menu_checkbox' template");
delete ig;
}
}
}
}
}
}
break;
case HTML_I:
@ -2422,6 +2542,9 @@ namespace NLGUI
_GroupListAdaptor = NULL;
_DocumentUrl = "";
_UrlFragment.clear();
_RefreshUrl.clear();
_NextRefreshTime = 0.0;
_LastRefreshTime = 0.0;
// Register
CWidgetManager::getInstance()->registerClockMsgTarget(this);
@ -2464,6 +2587,7 @@ namespace NLGUI
DefaultFormTextGroup = "edit_box_widget";
DefaultFormTextAreaGroup = "edit_box_widget_multiline";
DefaultFormSelectGroup = "html_form_select_widget";
DefaultFormSelectBoxMenuGroup = "html_form_select_box_menu_widget";
DefaultCheckBoxBitmapNormal = "checkbox_normal.tga";
DefaultCheckBoxBitmapPushed = "checkbox_pushed.tga";
DefaultCheckBoxBitmapOver = "checkbox_over.tga";
@ -3403,7 +3527,34 @@ namespace NLGUI
bool CGroupHTML::handleEvent (const NLGUI::CEventDescriptor& eventDesc)
{
bool traited = CGroupScrollText::handleEvent (eventDesc);
bool traited = false;
if (eventDesc.getType() == NLGUI::CEventDescriptor::mouse)
{
const NLGUI::CEventDescriptorMouse &mouseEvent = (const NLGUI::CEventDescriptorMouse &)eventDesc;
if (mouseEvent.getEventTypeExtended() == NLGUI::CEventDescriptorMouse::mousewheel)
{
// Check if mouse wheel event was on any of multiline select box widgets
// Must do this before CGroupScrollText
for (uint i=0; i<_Forms.size() && !traited; i++)
{
for (uint j=0; j<_Forms[i].Entries.size() && !traited; j++)
{
if (_Forms[i].Entries[j].SelectBox)
{
if (_Forms[i].Entries[j].SelectBox->handleEvent(eventDesc))
{
traited = true;
break;
}
}
}
}
}
}
if (!traited)
traited = CGroupScrollText::handleEvent (eventDesc);
if (eventDesc.getType() == NLGUI::CEventDescriptor::system)
{
@ -3413,8 +3564,15 @@ namespace NLGUI
// Handle now
handle ();
}
if (systemEvent.getEventTypeExtended() == NLGUI::CEventDescriptorSystem::activecalledonparent)
{
if (!((NLGUI::CEventDescriptorActiveCalledOnParent &) systemEvent).getActive())
{
// stop refresh when window gets hidden
_NextRefreshTime = 0;
}
}
}
return traited;
}
@ -3550,6 +3708,7 @@ namespace NLGUI
CViewText *viewText = new CViewText ("", (string("Error : ")+msg).c_str());
viewText->setColor (ErrorColor);
viewText->setModulateGlobalColor(ErrorColorGlobalColor);
viewText->setMultiLine (true);
getParagraph()->addChild (viewText);
if(!_TitlePrefix.empty())
setTitle (_TitlePrefix);
@ -3985,6 +4144,45 @@ namespace NLGUI
return NULL;
}
// ***************************************************************************
CGroupMenu *CGroupHTML::addSelectBox(const std::string &templateName, const char *name)
{
// In a paragraph ?
if (!_Paragraph)
{
newParagraph (0);
paragraphChange ();
}
// Not added ?
std::vector<std::pair<std::string,std::string> > templateParams;
templateParams.push_back(std::pair<std::string,std::string> ("id", name));
CInterfaceGroup *group = CWidgetManager::getInstance()->getParser()->createGroupInstance(templateName.c_str(),
getParagraph()->getId(), &(templateParams[0]), (uint)templateParams.size());
// Group created ?
if (group)
{
// Set the content
CGroupMenu *sb = dynamic_cast<CGroupMenu *>(group);
if (!sb)
{
nlwarning("'%s' template has bad type, CGroupMenu expected", templateName.c_str());
delete sb;
return NULL;
}
else
{
getParagraph()->addChild (sb);
paragraphChange ();
return sb;
}
}
// No group created
return NULL;
}
// ***************************************************************************
CCtrlButton *CGroupHTML::addButton(CCtrlButton::EType type, const std::string &/* name */, const std::string &normalBitmap, const std::string &pushedBitmap,
@ -4409,6 +4607,21 @@ namespace NLGUI
// handle curl downloads
checkDownloads();
// handle refresh timer
if (_NextRefreshTime > 0 && _NextRefreshTime <= (times.thisFrameMs / 1000.0f) )
{
// there might be valid uses for 0sec refresh, but two in a row is probably a mistake
if (_NextRefreshTime - _LastRefreshTime >= 1.0)
{
_LastRefreshTime = _NextRefreshTime;
doBrowse(_RefreshUrl.c_str());
}
else
nlwarning("Ignore second 0sec http-equiv refresh in a row (url '%s')", _URL.c_str());
_NextRefreshTime = 0;
}
if (_Connecting)
{
// Check timeout if needed
@ -4523,6 +4736,24 @@ namespace NLGUI
entryData.fromUtf8(form.Entries[i].SelectValues[cb->getSelection()]);
addEntry = true;
}
else if (form.Entries[i].SelectBox)
{
CGroupMenu *sb = form.Entries[i].SelectBox;
CGroupSubMenu *rootMenu = sb->getRootMenu();
if (rootMenu)
{
for(uint j=0; j<rootMenu->getNumLine(); ++j)
{
CInterfaceGroup *ig = rootMenu->getUserGroupLeft(j);
if (ig)
{
CCtrlBaseButton *cb = dynamic_cast<CCtrlBaseButton *>(ig->getCtrl("b"));
if (cb && cb->getPushed())
formfields.add(form.Entries[i].Name, form.Entries[i].SelectValues[j]);
}
}
}
}
// This is a hidden value
else
{
@ -4782,6 +5013,8 @@ namespace NLGUI
//
_Browsing = true;
_DocumentUrl = _URL;
_NextRefreshTime = 0;
_RefreshUrl.clear();
// clear content
beginBuild();
@ -5679,5 +5912,6 @@ namespace NLGUI
return ret;
}
}

View file

@ -2496,6 +2496,17 @@ namespace NLGUI
}
}
// ------------------------------------------------------------------------------------------------
void CGroupMenu::setMinH(sint32 minH)
{
if ( _RootMenu )
{
_RootMenu->_GroupList->setMinH(minH-_RootMenu->getResizeFromChildHMargin());
_RootMenu->_GroupList->setH(minH-_RootMenu->getResizeFromChildHMargin());
_RootMenu->setH(minH-_RootMenu->getResizeFromChildHMargin());
}
}
// ------------------------------------------------------------------------------------------------
void CGroupMenu::setGrayedLine(uint line, bool g)
{

View file

@ -1314,6 +1314,188 @@
params="value=add(@UI:PHRASE:SELECT_MEMORY,-1)" />
</group>
<tree node="gestionsets" />
<!-- second hands bar -->
<define id="gestionsets_h" value="1" />
<define id="gestionsets_v" value="2" />
<variable entry="UI:SAVE:GESTIONSETS2_MODE" type="sint32" value="0" />
<proc id="gestionsets2_proc_active">
<action handler="set" params="dblink=UI:VARIABLES:ISACTIVE:SETS2|value=1"/>
<action handler="proc" params="gestionsets2_proc_mode" />
</proc>
<proc id="gestionsets2_proc_set">
<action handler="set" params="dblink=UI:SAVE:GESTIONSETS2_MODE|value=@0"/>
<action handler="proc" params="gestionsets2_proc_mode" />
</proc>
<proc id="gestionsets2_proc_mode">
<action handler="proc" cond="eq(@UI:SAVE:GESTIONSETS2_MODE,%gestionsets_h)" params="gestionsets2_proc_horiz"/>
<action handler="proc" cond="ne(@UI:SAVE:GESTIONSETS2_MODE,%gestionsets_h)" params="gestionsets2_proc_vert"/>
</proc>
<proc id="gestionsets2_proc_vert">
<action handler="set" params="target='ui:interface:gestionsets2_menu:horiz:active'|value=1"/>
<action handler="set" params="target='ui:interface:gestionsets2_menu:vert:active'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:w'|value=68"/>
<action handler="set" params="target='ui:interface:gestionsets2:h'|value=300"/>
<action handler="set" params="target='ui:interface:gestionsets2:select_memory:active'|value=1"/>
<action handler="set" params="target='ui:interface:gestionsets2:select_memory_h:active'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:w'|value=68"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:h'|value=300"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:w'|value=68"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:h'|value=300"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s0:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s0:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s1:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s1:y'|value=-28"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s2:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s2:y'|value=-56"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s3:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s3:y'|value=-84"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s4:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s4:y'|value=-112"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s5:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s5:y'|value=-140"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s6:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s6:y'|value=-168"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s7:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s7:y'|value=-196"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s8:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s8:y'|value=-224"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s9:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s9:y'|value=-252"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s10:x'|value=26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s10:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s11:x'|value=26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s11:y'|value=-28"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s12:x'|value=26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s12:y'|value=-56"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s13:x'|value=26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s13:y'|value=-84"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s14:x'|value=26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s14:y'|value=-112"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s15:x'|value=26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s15:y'|value=-140"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s16:x'|value=26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s16:y'|value=-168"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s17:x'|value=26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s17:y'|value=-196"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s18:x'|value=26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s18:y'|value=-224"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s19:x'|value=26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s19:y'|value=-252"/>
</proc>
<proc id="gestionsets2_proc_horiz">
<action handler="set" params="target='ui:interface:gestionsets2_menu:horiz:active'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2_menu:vert:active'|value=1"/>
<action handler="set" params="target='ui:interface:gestionsets2:w'|value=315"/>
<action handler="set" params="target='ui:interface:gestionsets2:h'|value=52"/>
<action handler="set" params="target='ui:interface:gestionsets2:select_memory:active'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:select_memory_h:active'|value=1"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:w'|value=315"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:h'|value=52"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:w'|value=315"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:h'|value=52"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s0:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s0:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s1:x'|value=28"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s1:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s2:x'|value=56"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s2:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s3:x'|value=84"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s3:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s4:x'|value=112"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s4:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s5:x'|value=140"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s5:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s6:x'|value=168"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s6:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s7:x'|value=196"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s7:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s8:x'|value=224"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s8:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s9:x'|value=252"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s9:y'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s10:x'|value=0"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s10:y'|value=-26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s11:x'|value=28"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s11:y'|value=-26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s12:x'|value=56"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s12:y'|value=-26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s13:x'|value=84"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s13:y'|value=-26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s14:x'|value=112"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s14:y'|value=-26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s15:x'|value=140"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s15:y'|value=-26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s16:x'|value=168"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s16:y'|value=-26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s17:x'|value=196"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s17:y'|value=-26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s18:x'|value=224"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s18:y'|value=-26"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s19:x'|value=252"/>
<action handler="set" params="target='ui:interface:gestionsets2:header_closed:shortcuts:s19:y'|value=-26"/>
</proc>
<group type="menu" id="gestionsets2_menu" extends="base_menu_with_color">
<action id="horiz" name="uiHorizontal" handler="proc" params="gestionsets2_proc_set|%gestionsets_h"/>
<action id="vert" name="uiVertical" handler="proc" params="gestionsets2_proc_set|%gestionsets_v"/>
<separator />
</group>
<group type="container"
id="gestionsets2"
w="68"
@ -1322,7 +1504,7 @@
header_active="false"
right_button="false"
group_onclick_r="active_menu"
group_params_r="menu=ui:interface:base_menu_with_color"
group_params_r="menu=ui:interface:gestionsets2_menu"
movable="true"
active="true"
opened="false"
@ -1330,8 +1512,8 @@
global_color="false"
header_color="UI:SAVE:WIN:COLORS:INV"
locked="true"
on_active="set"
on_active_params="dblink=UI:VARIABLES:ISACTIVE:SETS2|value=1"
on_active="proc"
on_active_params="gestionsets2_proc_active"
on_deactive="set"
on_deactive_params="dblink=UI:VARIABLES:ISACTIVE:SETS2|value=0"
help_page="interf_action_bar.html">
@ -1501,9 +1683,66 @@
tooltip="uittHandSet"
tooltip_parent="win" />
</group>
<group type="select_number"
id="select_memory_h"
value="UI:PHRASE:SELECT_MEMORY_2"
loop="true"
min="1"
max="10"
x="0"
y="0"
w="300"
h="52"
active="false"
posparent="shortcuts"
posref="MM MM"
delta="1">
<view type="bitmap"
id="slot_number"
posref="MR MR"
texture="W_slot_number.tga" />
<view type="text"
id="number"
posparent="slot_number"
posref="MM MM"
x="0"
y="0"
color="255 255 255 255"
fontsize="12"
shadow="true"
hardtext="0"
global_color="false" />
<ctrl type="button"
id="arrow_up"
button_type="push_button"
posref="TM BM"
posparent="slot_number"
x="0"
y="0"
tx_normal="W_arrow_up_1.tga"
tx_pushed="W_arrow_up_1.tga"
tx_over="W_button_12_over.tga"
tooltip="uittHandSet"
tooltip_parent="win" />
<ctrl type="button"
id="arrow_down"
button_type="push_button"
posref="BM TM"
posparent="slot_number"
x="0"
y="0"
tx_normal="W_arrow_down_1.tga"
tx_pushed="W_arrow_down_1.tga"
tx_over="W_button_12_over.tga"
tooltip="uittHandSet"
tooltip_parent="win" />
</group>
<link expr="@UI:PHRASE:SELECT_MEMORY_2"
action="phrase_select_memory_2"
params="value=add(@UI:PHRASE:SELECT_MEMORY_2,-1)" />
<link expr="depends(@UI:SAVE:GESTIONSETS2_MODE)"
action="proc"
params="gestionsets_proc_mode" />
</group>
<tree node="gestionsets2" />
<!-- hands -->

View file

@ -978,4 +978,23 @@
</group>
</template>
<template name="html_form_select_box_menu_widget"
keep="true"
id="sb">
<group type="menu"
id="#id"
posref="BL TL"
x="0"
y="0"
mouse_pos="false"
space="2"
shadow="false"
color="255 255 255 128"
color_over="255 255 255 255"
color_grayed="0 0 0 255"
fontsize="12"
highlight_over="255 255 255 128"
force_inside_screen="false"></group>
</template>
</interface_config>

View file

@ -6950,4 +6950,24 @@
global_color="false" />
</group>
</template>
<template name="html_form_select_box_menu_widget"
keep="true"
id="sb">
<group type="menu"
id="#id"
posref="BL TL"
x="0"
y="0"
mouse_pos="false"
space="2"
shadow="false"
color="255 255 255 128"
color_over="255 255 255 255"
color_grayed="0 0 0 255"
fontsize="12"
highlight_over="255 255 255 128"
force_inside_screen="false"></group>
</template>
</interface_config>