本文整理汇总了C++中Params::caret_color方法的典型用法代码示例。如果您正苦于以下问题:C++ Params::caret_color方法的具体用法?C++ Params::caret_color怎么用?C++ Params::caret_color使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Params
的用法示例。
在下文中一共展示了Params::caret_color方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: getKey
LLMediaCtrl::LLMediaCtrl( const Params& p) :
LLPanel( p.name, p.rect, FALSE),
LLInstanceTracker<LLMediaCtrl, LLUUID>(LLUUID::generateNewID()),
mTextureDepthBytes( 4 ),
mBorder(NULL),
mFrequentUpdates( true ),
mForceUpdate( false ),
mHomePageUrl( "" ),
mAlwaysRefresh( false ),
mMediaSource( 0 ),
mTakeFocusOnClick( p.focus_on_click ),
mCurrentNavUrl( "about:blank" ),
mStretchToFill( true ),
mMaintainAspectRatio ( true ),
mDecoupleTextureSize ( false ),
mTextureWidth ( 1024 ),
mTextureHeight ( 1024 ),
mClearCache(false),
mHomePageMimeType(p.initial_mime_type),
mErrorPageURL(p.error_page_url),
mTrusted(p.trusted_content),
mHoverTextChanged(false),
mContextMenu()
{
{
LLColor4 color = p.caret_color().get();
setCaretColor( (unsigned int)color.mV[0], (unsigned int)color.mV[1], (unsigned int)color.mV[2] );
}
setHomePageUrl(p.start_url, p.initial_mime_type);
setBorderVisible(p.border_visible);
setDecoupleTextureSize(p.decouple_texture_size);
setTextureSize(p.texture_width, p.texture_height);
if(!getDecoupleTextureSize())
{
S32 screen_width = ll_round((F32)getRect().getWidth() * LLUI::getScaleFactor().mV[VX]);
S32 screen_height = ll_round((F32)getRect().getHeight() * LLUI::getScaleFactor().mV[VY]);
setTextureSize(screen_width, screen_height);
}
mMediaTextureID = getKey();
// We don't need to create the media source up front anymore unless we have a non-empty home URL to navigate to.
/*if(!mHomePageUrl.empty())
{
navigateHome();
}*/
//LLRect border_rect( 0, getRect().getHeight() + 2, getRect().getWidth() + 2, 0 );
}
示例2: llround
LLMediaCtrl::LLMediaCtrl( const Params& p) :
LLPanel( p ),
LLInstanceTracker<LLMediaCtrl, LLUUID>(LLUUID::generateNewID()),
mTextureDepthBytes( 4 ),
mBorder(NULL),
mFrequentUpdates( true ),
mForceUpdate( false ),
mHomePageUrl( "" ),
mAlwaysRefresh( false ),
mMediaSource( 0 ),
mTakeFocusOnClick( p.focus_on_click ),
mCurrentNavUrl( "" ),
mStretchToFill( true ),
mMaintainAspectRatio ( true ),
mDecoupleTextureSize ( false ),
mTextureWidth ( 1024 ),
mTextureHeight ( 1024 ),
mClearCache(false),
mHomePageMimeType(p.initial_mime_type),
mErrorPageURL(p.error_page_url),
mTrusted(p.trusted_content),
mWindowShade(NULL),
mHoverTextChanged(false),
mContextMenu(NULL)
{
{
LLColor4 color = p.caret_color().get();
setCaretColor( (unsigned int)color.mV[0], (unsigned int)color.mV[1], (unsigned int)color.mV[2] );
}
setHomePageUrl(p.start_url, p.initial_mime_type);
setBorderVisible(p.border_visible);
setDecoupleTextureSize(p.decouple_texture_size);
setTextureSize(p.texture_width, p.texture_height);
if(!getDecoupleTextureSize())
{
S32 screen_width = llround((F32)getRect().getWidth() * LLUI::getScaleFactor().mV[VX]);
S32 screen_height = llround((F32)getRect().getHeight() * LLUI::getScaleFactor().mV[VY]);
setTextureSize(screen_width, screen_height);
}
mMediaTextureID = getKey();
// We don't need to create the media source up front anymore unless we have a non-empty home URL to navigate to.
if(!mHomePageUrl.empty())
{
navigateHome();
}
LLWindowShade::Params params;
params.name = "notification_shade";
params.rect = getLocalRect();
params.follows.flags = FOLLOWS_ALL;
params.modal = true;
mWindowShade = LLUICtrlFactory::create<LLWindowShade>(params);
addChild(mWindowShade);
}