57 #ifndef _RNR_WIN_BUTTON_MENU_H 58 #define _RNR_WIN_BUTTON_MENU_H 63 #include "rnr/rnrconfig.h" 72 #if defined(ARCH_overo) 73 const char*
const WinIconDirDft =
"/usr/local/share/appkit/images/icons";
75 const char*
const WinIconDirDft =
"/prj/share/appkit/images/icons";
119 const std::string &strAltText,
120 const std::string &strTagNormal,
121 const std::string &strToolTipNormal =
"",
122 const std::string &strTagActive =
"",
123 const std::string &strToolTipActive =
"") :
246 m_strIconPath = strIconPath;
263 if( m_strIconPath.empty() )
265 m_strIconPath = strIconDir;
269 m_strIconPath = m_strIconPath + PATH_SEP_STR + strIconDir;
280 if( m_strIconPath.empty() )
282 m_strIconPath = strIconDir;
286 m_strIconPath = strIconDir + PATH_SEP_STR + m_strIconPath;
297 m_strIconPath = strIconPath;
307 return m_strIconPath;
332 const std::string &strAltText,
333 const std::string &strIconNormal,
334 const std::string &strToolTipNormal =
"",
335 const std::string &strIconActive =
"",
336 const std::string &strToolTipActive =
"")
362 const std::string &strLabelNormal,
363 const std::string &strToolTipNormal =
"",
364 const std::string &strLabelActive =
"",
365 const std::string &strToolTipActive =
"")
378 virtual void bind(
Win *pWin);
383 virtual void unbind();
392 return m_nCurrentEvent;
404 if( nNewEvent != m_nCurrentEvent )
406 m_nPreviousEvent = m_nCurrentEvent;
408 m_nCurrentEvent = nNewEvent;
409 return m_nCurrentEvent;
419 return m_nPreviousEvent;
429 return m_mapButtons.size();
443 if( m_mapButtons.find(nEvent) != m_mapButtons.end() )
445 eState = m_mapButtons[nEvent]->m_eState;
458 MapBttns_T::iterator pos;
460 if( (pos = m_mapButtons.find(nEvent)) != m_mapButtons.end() )
462 changeButtonState(pos->second, eNewState);
474 void setButtonStateList(
const std::string &strEvent, ...);
479 void resetAllButtonStates();
498 std::string makeIconPath(
const std::string &strIconFile);
514 static void onMenuButtonClick(
int nEvent,
void *user_data);
520 #endif // _RNR_WIN_BUTTON_MENU_H
WinButtonType
Window button types.
RoadNarrows Robotics Win abstract base class interface.
RNR Win window abstract base class.