本文整理汇总了C++中LLMenuGL::appendSeparator方法的典型用法代码示例。如果您正苦于以下问题:C++ LLMenuGL::appendSeparator方法的具体用法?C++ LLMenuGL::appendSeparator怎么用?C++ LLMenuGL::appendSeparator使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类LLMenuGL
的用法示例。
在下文中一共展示了LLMenuGL::appendSeparator方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: major_dir_rect
LLNetMap::LLNetMap(
const std::string& name,
const LLRect& rect,
const LLColor4& bg_color )
:
LLUICtrl(name, rect, FALSE, NULL, NULL), mBackgroundColor( bg_color ),
mObjectMapTPM(1.f),
mObjectMapPixels(255.f),
mTargetPanX( 0.f ),
mTargetPanY( 0.f ),
mCurPanX( 0.f ),
mCurPanY( 0.f ),
mUpdateNow( FALSE )
{
mPixelsPerMeter = gMiniMapScale / REGION_WIDTH_METERS;
LLNetMap::sRotateMap = gSavedSettings.getBOOL( "MiniMapRotate" );
// Surface texture is dynamically generated/updated.
// createObjectImage();
mObjectImageCenterGlobal = gAgent.getCameraPositionGlobal();
// TODO: exteralize hardcoded constants.
const S32 DIR_WIDTH = 10;
const S32 DIR_HEIGHT = 10;
LLRect major_dir_rect( 0, DIR_HEIGHT, DIR_WIDTH, 0 );
const LLColor4 minor_color( 1.f, 1.f, 1.f, .7f );
const LLRect minor_dir_rect( 0, DIR_HEIGHT, DIR_WIDTH * 2, 0 );
// Note: removing special treatment for north compass point (DEV-10559). -MG
//mTextBoxNorth = new LLTextBox( "N", major_dir_rect );
//mTextBoxNorth->setFontStyle(LLFontGL::DROP_SHADOW_SOFT);
//addChild( mTextBoxNorth );
mTextBoxNorth = new LLTextBox( std::string("N"), major_dir_rect );
mTextBoxNorth->setColor( minor_color );
addChild( mTextBoxNorth );
mTextBoxEast = new LLTextBox( std::string("E"), major_dir_rect );
mTextBoxEast->setColor( minor_color );
addChild( mTextBoxEast );
major_dir_rect.mRight += 1 ;
mTextBoxWest = new LLTextBox( std::string("W"), major_dir_rect );
mTextBoxWest->setColor( minor_color );
addChild( mTextBoxWest );
major_dir_rect.mRight -= 1 ;
mTextBoxSouth = new LLTextBox( std::string("S"), major_dir_rect );
mTextBoxSouth->setColor( minor_color );
addChild( mTextBoxSouth );
mTextBoxSouthEast = new LLTextBox( std::string("SE"), minor_dir_rect );
mTextBoxSouthEast->setColor( minor_color );
addChild( mTextBoxSouthEast );
mTextBoxNorthEast = new LLTextBox( std::string("NE"), minor_dir_rect );
mTextBoxNorthEast->setColor( minor_color );
addChild( mTextBoxNorthEast );
mTextBoxSouthWest = new LLTextBox( std::string("SW"), minor_dir_rect );
mTextBoxSouthWest->setColor( minor_color );
addChild( mTextBoxSouthWest );
mTextBoxNorthWest = new LLTextBox( std::string("NW"), minor_dir_rect );
mTextBoxNorthWest->setColor( minor_color );
addChild( mTextBoxNorthWest );
// Right-click menu
LLMenuGL* menu;
menu = new LLMenuGL(std::string("popup"));
menu->setCanTearOff(FALSE);
menu->append(new LLMenuItemCallGL(std::string("Zoom Close"), handleZoomLevel,
NULL, (void*)2) );
menu->append(new LLMenuItemCallGL(std::string("Zoom Medium"), handleZoomLevel,
NULL, (void*)1) );
menu->append(new LLMenuItemCallGL(std::string("Zoom Far"), handleZoomLevel,
NULL, (void*)0) );
menu->appendSeparator();
menu->append(new LLMenuItemCallGL(std::string("Stop Tracking"), &LLTracker::stopTracking,
&LLTracker::isTracking, NULL) );
menu->setVisible(FALSE);
addChild(menu);
mPopupMenuHandle = menu->getHandle();
sInstance = this;
}