Exemple #1
0
// URL变更的回调函数
void CDuiWkeView::onURLChanged(const struct _wkeClientHandler* clientHandler, const wkeString URL)
{
	// 查找对应的控件对象
	CDuiWkeView* pDuiWkeView = CDuiWkeView::GetWkeViewByClientHandler(clientHandler);
	if(pDuiWkeView)
	{
		pDuiWkeView->setURL(wkeToStringW(URL));
		pDuiWkeView->SendMessage(MSG_CONTROL_EVENT, (WPARAM)WKE_EVENT_URLCHANGED, (LPARAM)wkeToStringW(URL));
	}
}
Exemple #2
0
// URL变更的回调函数
void CDuiWkeView::onURLChanged(const struct _wkeClientHandler* clientHandler, const wkeString URL)
{
	// 查找对应的控件对象
	CDuiWkeView* pDuiWkeView = CDuiWkeView::GetWkeViewByClientHandler(clientHandler);
	if(pDuiWkeView)
	{
#ifdef _UNICODE
		pDuiWkeView->setURL(wkeToStringW(URL));
		pDuiWkeView->SendMessage(MSG_CONTROL_EVENT, (WPARAM)WKE_EVENT_URLCHANGED, (LPARAM)wkeToStringW(URL));
#else
		const wchar_t *pWchar=wkeToStringW(URL);
		CStringA strA=CEncodingUtil::UnicodeToAnsi(pWchar);
		pDuiWkeView->setURL(strA);
		pDuiWkeView->SendMessage(MSG_CONTROL_EVENT, (WPARAM)WKE_EVENT_URLCHANGED, (LPARAM)(LPCTSTR)(strA));
#endif
	}
}
void onTitleChanged(const struct _wkeClientHandler* clientHandler, const wkeString title)
{
//	MessageBox(hwnd, wkeToStringW(title), _T(""), 0);
	HWND hwnd = CFrameWnd::MainWnd()->GetHWND();
	if (::IsWindow(hwnd) )
	{
		::PostMessage(hwnd, WM_USER_TITLE_CHANGE, (WPARAM)wkeToStringW(title), (LPARAM)0);
	}
}
Exemple #4
0
// 页面标题变更的回调函数
void CDuiWkeView::onTitleChanged(const struct _wkeClientHandler* clientHandler, const wkeString title)
{
	// 查找对应的控件对象
	CDuiWkeView* pDuiWkeView = CDuiWkeView::GetWkeViewByClientHandler(clientHandler);
	if(pDuiWkeView)
	{
		pDuiWkeView->SendMessage(MSG_CONTROL_EVENT, (WPARAM)WKE_EVENT_TITLECHANGED, (LPARAM)wkeToStringW(title));
	}
}
Exemple #5
0
void onTitleChanged(const wkeClientHandler* clientHandler, const wkeString title)
{
    HWND hWnd = 0;
    Ogre::Root::getSingleton().getAutoCreatedWindow()->getCustomAttribute("WINDOW", &hWnd);
    SetWindowTextW(hWnd, wkeToStringW(title));
}