本文整理汇总了C++中LinksWindow::Show方法的典型用法代码示例。如果您正苦于以下问题:C++ LinksWindow::Show方法的具体用法?C++ LinksWindow::Show怎么用?C++ LinksWindow::Show使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类LinksWindow
的用法示例。
在下文中一共展示了LinksWindow::Show方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: LinksWindow
struct graphics_device *ath_init_device()
{
LinksView *view;
LinksWindow *win;
struct graphics_device *dev = (struct graphics_device *)mem_calloc(sizeof(struct graphics_device));
if (!dev) return NULL;
dev->drv = &atheos_driver;
debug((unsigned char *)"1");
win = new LinksWindow(Rect(ath_win_x_pos, ath_win_y_pos, ath_win_x_pos + ath_win_x_size, ath_win_y_pos + ath_win_y_size));
debug((unsigned char *)"2");
if (!win) {
mem_free(dev);
return NULL;
}
debug((unsigned char *)"3");
view = new LinksView(win);
if (!view) {
delete win;
mem_free(dev);
return NULL;
}
view->dev = dev;
dev->driver_data = view;
ath_get_size(dev);
memcpy(&dev->clip, &dev->size, sizeof(struct rect));
debug((unsigned char *)"4");
win->Show();
win->MakeFocus();
debug((unsigned char *)"5");
return dev;
}
示例2: LinksWindow
struct graphics_device *ath_init_device()
{
LinksView *view;
LinksWindow *win;
struct graphics_device *dev = (struct graphics_device *)mem_calloc(sizeof(struct graphics_device));
if (!dev) return NULL;
debug((unsigned char *)"1");
retry:
win = new LinksWindow(Rect(ath_win_x_pos, ath_win_y_pos, ath_win_x_pos + ath_win_x_size, ath_win_y_pos + ath_win_y_size));
debug((unsigned char *)"2");
if (!win) {
if (out_of_memory(0, NULL, 0))
goto retry;
mem_free(dev);
return NULL;
}
debug((unsigned char *)"3");
retry2:
view = new LinksView(win);
if (!view) {
if (out_of_memory(0, NULL, 0))
goto retry2;
delete win;
mem_free(dev);
return NULL;
}
view->dev = dev;
dev->driver_data = view;
ath_get_size(dev);
memcpy(&dev->clip, &dev->size, sizeof(struct rect));
debug((unsigned char *)"4");
win->Show();
win->MakeFocus();
debug((unsigned char *)"5");
ath_win_x_pos += NEW_WINDOW_X_ADD;
ath_win_y_pos += NEW_WINDOW_Y_ADD;
if (ath_win_x_pos + ath_win_x_size > ath_x_size - NEW_WINDOW_X_MIN)
ath_win_x_pos = NEW_WINDOW_X_MIN;
if (ath_win_y_pos + ath_win_y_size > ath_y_size - NEW_WINDOW_Y_MIN)
ath_win_y_pos = ath_y_panel + NEW_WINDOW_Y_MIN;
return dev;
}