当前位置: 首页>>代码示例>>C++>>正文


C++ PositionWindow函数代码示例

本文整理汇总了C++中PositionWindow函数的典型用法代码示例。如果您正苦于以下问题:C++ PositionWindow函数的具体用法?C++ PositionWindow怎么用?C++ PositionWindow使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了PositionWindow函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: Hide

void
TBarView::HideDeskbar(bool hide)
{
	BRect screenFrame = (BScreen(Window())).Frame();

	if (hide) {
		Hide();
		PositionWindow(screenFrame);
		SizeWindow(screenFrame);
	} else {
		Show();
		SizeWindow(screenFrame);
		PositionWindow(screenFrame);
	}
}
开发者ID:Barrett17,项目名称:haiku-contacts-kit-old,代码行数:15,代码来源:BarView.cpp

示例2: PositionWindow

// Sets the content of the balloon (plain text only)
void CBalloonHelp::SetContent(const CString& strContent)
{
	m_strContent = strContent;
	// if already visible, resize & move
	if ( NULL != m_hWnd )
		PositionWindow();
}
开发者ID:alone888,项目名称:fengfang,代码行数:8,代码来源:BalloonHelp.cpp

示例3: set_type_hint

/** \brief
 *
 * Constructor. Sets up a modeless window and adds the HUD component to a
 * ScrolledWindow component.
 *
 */
HUDWindow::HUDWindow()
{
	set_type_hint(Gdk::WINDOW_TYPE_HINT_NORMAL);
	set_title(gettext("Player HUD Window"));
	set_resizable(true);
	set_decorated(true);
	set_position(Gtk::WIN_POS_CENTER);
	set_modal(false);
	set_icon( Gdk::Pixbuf::create_from_xpm_data( Helmet_xpm ) );

	PositionWindow();

    f_charView.AddHUDColumns();
    f_charView.set_border_width( 1 );
    //f_charView.update();
	//
    f_scrolledWindow.add( f_charView );
	f_scrolledWindow.set_policy( Gtk::POLICY_AUTOMATIC, Gtk::POLICY_AUTOMATIC );
	f_scrolledWindow.set_shadow_type( Gtk::SHADOW_IN  );
	f_scrolledWindow.set_border_width( 1 );
	//
	f_mainBox.pack_start( f_scrolledWindow, Gtk::PACK_EXPAND_WIDGET );
	f_mainBox.pack_start( f_statusBox, Gtk::PACK_SHRINK );
	//
	add( f_mainBox );

	f_statusBox.Update();
	
	show_all_children();
}
开发者ID:m2osw,项目名称:turnwatcher,代码行数:36,代码来源:HUDWindow.cpp

示例4: MythOSDWindow

void OSD::LoadWindows(void)
{
    static const char* default_windows[7] = {
        "osd_message", "osd_input", "program_info", "browse_info", "osd_status",
        "osd_program_editor", "osd_debug"};

    for (int i = 0; i < 7; i++)
    {
        const char* window = default_windows[i];
        MythOSDWindow *win = new MythOSDWindow(NULL, window, true);

        win->SetPainter(m_CurrentPainter);
        if (win->Create())
        {
            PositionWindow(win);
            LOG(VB_PLAYBACK, LOG_INFO, LOC +
                QString("Loaded window %1").arg(window));
            m_Children.insert(window, win);
        }
        else
        {
            LOG(VB_GENERAL, LOG_ERR, LOC + QString("Failed to load window %1")
                .arg(window));
            delete win;
        }
    }
}
开发者ID:jshattoc,项目名称:mythtv,代码行数:27,代码来源:osd.cpp

示例5: GetStyle

void CHyperLink::PreSubclassWindow() 
{
	// We want to get mouse clicks via STN_CLICKED
	DWORD dwStyle = GetStyle();
	::SetWindowLong(m_hWnd, GWL_STYLE, dwStyle | SS_NOTIFY);
	
	// Set the URL as the window text
	if (m_strURL.IsEmpty())
		GetWindowText(m_strURL);

	// Check that the window text isn't empty. If it is, set it as the URL.
	CString strWndText;
	GetWindowText(strWndText);
	if (strWndText.IsEmpty()) {
		ASSERT(!m_strURL.IsEmpty());	// Window and URL both empty. DUH!
		SetWindowText(m_strURL);
	}

	// Adjust size of window to fit URL if necessary
	PositionWindow();		

	// Load up the (standard) hyperlink cursor
	m_hLinkCursor = AfxGetApp()->LoadStandardCursor(IDC_ARROW);

	// Create the tooltip
	CRect rect; 
	GetClientRect(rect);
	m_ToolTip.Create(this);
	m_ToolTip.AddTool(this, m_strURL, rect, TOOLTIP_ID);

	CStatic::PreSubclassWindow();
}
开发者ID:CrawlingForward,项目名称:BWChess,代码行数:32,代码来源:HyperLink.cpp

示例6: ActiveMonitors

void OSD::InitMeterWnd(MeterWnd &mWnd) {
    mWnd.AlwaysOnTop(_settings->AlwaysOnTop());
    mWnd.HideAnimation(_settings->HideAnim(), _settings->HideSpeed());
    mWnd.VisibleDuration(_settings->HideDelay());

    std::vector<Monitor> monitors = ActiveMonitors();
    for (unsigned int i = 1; i < monitors.size(); ++i) {
        mWnd.Clone();
    }

    PositionWindow(monitors[0], mWnd);
    std::vector<LayeredWnd *> clones = mWnd.Clones();
    for (unsigned int i = 1; i < monitors.size(); ++i) {
        PositionWindow(monitors[i], *clones[i - 1]);
    }
}
开发者ID:tg44,项目名称:3RVX,代码行数:16,代码来源:OSD.cpp

示例7: PositionWindow

void CHyperLink::SetAutoSize(bool bAutoSize /* = true */)
{
    m_bAdjustToFit = bAutoSize;

    if (::IsWindow(GetSafeHwnd()))
        PositionWindow();
}
开发者ID:jjayne,项目名称:nSIGHTS,代码行数:7,代码来源:HyperLink.cpp

示例8: Create

HWND
CalendarCtrl::CreateGrid(HWND hwndparent, DataView *dv, wyBool isDate, wyBool isResult)
{
	m_hwndparent= hwndparent;
    wyChar* temp = dv->m_data->m_rowarray->GetRowExAt(CustomGrid_GetCurSelRow(dv->m_hwndgrid))->m_row[CustomGrid_GetCurSelCol(dv->m_hwndgrid)];
	if(temp)
		m_orgdata.SetAs(temp);
	else
		m_orgdata.SetAs(L"(NULL)");
	m_isDate = isDate;
	m_date.SetAs(m_orgdata);
	m_dv	= dv;
	m_isResult = isResult;

	m_hwnd = Create();
	
	if(isDate)
		ShowWindow(GetDlgItem(m_hwnd,IDC_DATETIMEPICKER1),SW_HIDE);

	CustomGrid_GetSubItemRect(m_hwndparent, m_row, m_col, &m_rectCell);
 
	PositionWindow(&m_rectCell);
	ShowWindow(m_hwnd,SW_SHOW);
	
	return m_hwnd;
}
开发者ID:sylarhl,项目名称:sqlgoy,代码行数:26,代码来源:CalendarCtrl.cpp

示例9: SetWindowText

// Sets the title of the balloon
void CBalloonHelp::SetTitle(const CString& strTitle)
{
	SetWindowText(strTitle);
	// if already visible, resize & move
	if ( NULL != m_hWnd )
		PositionWindow();
}
开发者ID:alone888,项目名称:fengfang,代码行数:8,代码来源:BalloonHelp.cpp

示例10: PositionWindow

void CHyperLink::SetAutoSize(BOOL bAutoSize /* = TRUE */)
{
    m_bAdjustToFit = bAutoSize;

    if (::IsWindow(GetSafeHwnd()))
        PositionWindow();
}
开发者ID:likebeta,项目名称:code-snippets,代码行数:7,代码来源:HyperLink.cpp

示例11: SetUrl

/*
	SetUrl()
*/
void CHyperLink::SetUrl(LPCSTR lpcszUrl)
{
	m_strUrl.Format("%s",lpcszUrl);

	if(m_bAdjustToFit)
		if(::IsWindow(GetSafeHwnd()))
			PositionWindow();
}
开发者ID:code4bones,项目名称:crawlpaper,代码行数:11,代码来源:CHyperLink.cpp

示例12: PositionWindow

/////////////////////////////////////////////////////////////////////////////
// CXHyperLink operations
void CXHyperLink::SetURL(CString strURL)
{
	m_strURL = strURL;

	if (::IsWindow(GetSafeHwnd())) 
	{
		PositionWindow();		
	}
}
开发者ID:wermanhme1990,项目名称:xcommon,代码行数:11,代码来源:XHyperlink.cpp

示例13: ASSERT

///////////////////////////////////////////////////////////////////////////////
// SetWindowText
void CXHyperLink::SetWindowText(LPCTSTR lpszString)
{
	ASSERT(lpszString);
	if (!lpszString)
		return;
	CStatic::SetWindowText(_T(""));
	RedrawWindow();
	CStatic::SetWindowText(lpszString);
	PositionWindow();
}
开发者ID:RNCan,项目名称:WeatherBasedSimulationFramework,代码行数:12,代码来源:XHyperLink.cpp

示例14: ShowFrameRate

void ShowFrameRate(FrameRateWnd *w, int frameRate)
{
    if (w->frameRate == frameRate) {
        return;
    }
    w->frameRate = frameRate;
    SIZE s = GetIdealSize(w);
    PositionWindow(w, s);
    ScheduleRepaint(w->hwnd);
}
开发者ID:UIKit0,项目名称:sumatrapdf,代码行数:10,代码来源:FrameRateWnd.cpp

示例15: SetFont

void CStaticHyperLink::SetDisplayString(CString strDisplay)
{
	m_strDisplay = strDisplay;
	if (::IsWindow(GetSafeHwnd())) 
	{
		SetFont();
		SetWindowText(m_strDisplay);
		PositionWindow();
	}
}
开发者ID:killbug2004,项目名称:WSProf,代码行数:10,代码来源:StaticHyperLink.cpp


注:本文中的PositionWindow函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。