本文整理汇总了C++中bprivate::AppServerLink::Flush方法的典型用法代码示例。如果您正苦于以下问题:C++ AppServerLink::Flush方法的具体用法?C++ AppServerLink::Flush怎么用?C++ AppServerLink::Flush使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类bprivate::AppServerLink
的用法示例。
在下文中一共展示了AppServerLink::Flush方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1:
void
BApplication::HideCursor()
{
BPrivate::AppServerLink link;
link.StartMessage(AS_HIDE_CURSOR);
link.Flush();
}
示例2: _
/*! \brief Cleans up any memory allocated by the bitmap and
informs the server to do so as well (if needed).
*/
void
BBitmap::_CleanUp()
{
if (fWindow != NULL) {
if (fWindow->Lock())
delete fWindow;
fWindow = NULL;
// this will leak fWindow if it couldn't be locked
}
if (fBasePointer == NULL)
return;
if ((fFlags & B_BITMAP_NO_SERVER_LINK) != 0) {
free(fBasePointer);
} else if (fServerToken != -1) {
BPrivate::AppServerLink link;
// AS_DELETE_BITMAP:
// Attached Data:
// 1) int32 server token
link.StartMessage(AS_DELETE_BITMAP);
link.Attach<int32>(fServerToken);
link.Flush();
// The server areas are deleted via kMsgDeleteServerMemoryArea message
fArea = -1;
fServerToken = -1;
fAreaOffset = -1;
BAutolock _(sBitmapListLock);
sBitmapList.RemoveItem(this);
}
fBasePointer = NULL;
}
示例3:
void
set_mouse_mode(mode_mouse mode)
{
BPrivate::AppServerLink link;
link.StartMessage(AS_SET_MOUSE_MODE);
link.Attach<mode_mouse>(mode);
link.Flush();
}
示例4:
void
BCursor::_FreeCursorData()
{
// Notify server to deallocate server-side objects for this cursor
if (fNeedToFree) {
BPrivate::AppServerLink link;
link.StartMessage(AS_DELETE_CURSOR);
link.Attach<int32>(fServerToken);
link.Flush();
}
}
示例5: sizeof
// Private function used to replace the R5 hack which sets a system font
void
_set_system_font_(const char* which, font_family family, font_style style,
float size)
{
// R5 used a global area offset table to set the system fonts in the Font
// preferences panel. Bleah.
BPrivate::AppServerLink link;
link.StartMessage(AS_SET_SYSTEM_FONT);
link.AttachString(which, B_OS_NAME_LENGTH);
link.AttachString(family, sizeof(font_family));
link.AttachString(style, sizeof(font_style));
link.Attach<float>(size);
link.Flush();
}
示例6:
/*! \brief Private function which sets the window decorator for the system.
\param entry_ref to the decorator to set
Will return detailed error status via status_t
*/
status_t
set_decorator(const BString& path)
{
BPrivate::AppServerLink link;
link.StartMessage(AS_SET_DECORATOR);
link.AttachString(path.String());
link.Flush();
status_t error = B_OK;
link.Read<status_t>(&error);
return error;
}
示例7: locker
status_t
BDragger::HideAllDraggers()
{
BPrivate::AppServerLink link;
link.StartMessage(AS_SET_SHOW_ALL_DRAGGERS);
link.Attach<bool>(false);
status_t status = link.Flush();
if (status == B_OK) {
DraggerManager* manager = DraggerManager::Default();
AutoLocker<DraggerManager> locker(manager);
manager->visible = false;
manager->visibleInitialized = true;
}
return status;
}