本文整理汇总了C++中Footer::GetHeight方法的典型用法代码示例。如果您正苦于以下问题:C++ Footer::GetHeight方法的具体用法?C++ Footer::GetHeight怎么用?C++ Footer::GetHeight使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Footer
的用法示例。
在下文中一共展示了Footer::GetHeight方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: OnActionPerformed
void BaseWordForm::OnActionPerformed(const Osp::Ui::Control& source, int actionId)
{
switch (actionId)
{
case ID_ADD_WORD:
{
if (__pAddWordDlg)
delete __pAddWordDlg;
__pAddWordDlg = new AddWord();
__pAddWordDlg->ShowPopup(this);
break;
}
case ID_MENU:
{
int hp = 0;
int wp = 0;
Header *header = GetHeader();
if (header)
{
int posy = GetBounds().height - GetClientAreaBounds().height;
Footer * footer = GetFooter();
if (footer)
posy -= footer->GetHeight();
hp = (posy - 10);
wp = header->GetWidth() - 10;
}
// Set the anchor position of the ContextMenu
__pContextMenu->SetPosition(Point(wp, hp));
// Show the ContextMenu
__pContextMenu->SetShowState(true);
__pContextMenu->Show();
break;
}
case ID_DICTIONARY:
{
ShowDictionary();
break;
}
case ID_MENU_INFO:
{
ShowInfoDlg();
break;
}
}
}
示例2: OnDraw
result BaseWordForm::OnDraw(void)
{
result r = Form::OnDraw();
Rectangle bound = GetBounds();
Canvas * canvas = GetCanvasN(bound);
if (!__pBGLogo)
__pBGLogo = Utils::GetBitmapN("bg_logo.png");
int x = bound.width / 2 - (__pBGLogo->GetWidth() / 2);
int y = bound.height - __pBGLogo->GetHeight() - 15;
Footer * footer = GetFooter();
if (footer)
{
y -= footer->GetHeight();
}
canvas->DrawBitmap(Point(x, y), *__pBGLogo);
delete canvas;
return r;
}