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


C++ GlobalDeleteAtom函数代码示例

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


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

示例1: UninitPasteSerial

void UninitPasteSerial()
{
  bInitPasteSerial=FALSE;

  if (nHotkeyDelimSkipID)
  {
    if (UnregisterHotKey(hMainWnd, nHotkeyDelimSkipID))
    {
      GlobalDeleteAtom(nHotkeyDelimSkipID);
      nHotkeyDelimSkipID=0;
    }
  }
  if (nHotkeyDelimAsTabID)
  {
    if (UnregisterHotKey(hMainWnd, nHotkeyDelimAsTabID))
    {
      GlobalDeleteAtom(nHotkeyDelimAsTabID);
      nHotkeyDelimAsTabID=0;
    }
  }
  if (nHotkeyDelimAsIsID)
  {
    if (UnregisterHotKey(hMainWnd, nHotkeyDelimAsIsID))
    {
      GlobalDeleteAtom(nHotkeyDelimAsIsID);
      nHotkeyDelimAsIsID=0;
    }
  }
}
开发者ID:embassy,项目名称:AkelPad,代码行数:29,代码来源:Clipboard.c

示例2: stop_scan

void Hotkey::End()
{
	stop_scan();
	GlobalDeleteAtom(ScanHotKeyId);
	stop_mainwindow();
	GlobalDeleteAtom(MainWindowHotKeyId);
	DestroyWindow(ServerWND);
}
开发者ID:virgree,项目名称:stardict-2.4.8,代码行数:8,代码来源:hotkey.cpp

示例3: bm_Cleanup

void bm_Cleanup(HINSTANCE hInstance)
{
  GlobalDeleteAtom(atomAlignStyle);
  GlobalDeleteAtom(atomTailSize);
  GlobalDeleteAtom(atomTimeout);
  GlobalDeleteAtom(atomFont);
  UnregisterClass(CLASSNAME_TOOLTIP,hInstance);
}
开发者ID:colistro123,项目名称:Nightfire-iniMod,代码行数:8,代码来源:balloon.c

示例4: WDML_HandleRequestReply

/******************************************************************
 *		WDML_HandleRequestReply
 *
 *
 */
static WDML_QUEUE_STATE WDML_HandleRequestReply(WDML_CONV* pConv, MSG* msg, WDML_XACT* pXAct, DWORD *ack)
{
    DDEACK		ddeAck;
    WINE_DDEHEAD	wdh;
    UINT_PTR		uiLo, uiHi;
    HSZ			hsz;

    if (WIN_GetFullHandle((HWND)msg->wParam) != pConv->hwndServer)
	return WDML_QS_PASS;

    switch (msg->message)
    {
    case WM_DDE_ACK:
        UnpackDDElParam(WM_DDE_ACK, msg->lParam, &uiLo, &uiHi);
        FreeDDElParam(WM_DDE_ACK, msg->lParam);
	GlobalDeleteAtom(uiHi);
       if (ack) *ack = uiLo;
	WDML_ExtractAck(uiLo, &ddeAck);
	pXAct->hDdeData = 0;
	if (ddeAck.fAck)
	    ERR("Positive answer should appear in NACK for a request, assuming negative\n");
	TRACE("Negative answer...\n");
	break;

    case WM_DDE_DATA:
        UnpackDDElParam(WM_DDE_DATA, msg->lParam, &uiLo, &uiHi);
	TRACE("Got the result (%08lx)\n", uiLo);

	hsz = WDML_MakeHszFromAtom(pConv->instance, uiHi);

	if (DdeCmpStringHandles(hsz, pXAct->hszItem) != 0)
	    return WDML_QS_PASS;

	pXAct->hDdeData = WDML_Global2DataHandle(pConv, (HGLOBAL)uiLo, &wdh);
	if (wdh.fRelease)
	{
	    GlobalFree((HGLOBAL)uiLo);
	}
	if (wdh.fAckReq)
	{
	    pConv->instance->lastError = DMLERR_MEMORY_ERROR;
	}
	else
	{
	    GlobalDeleteAtom(uiHi);
            FreeDDElParam(WM_DDE_ACK, msg->lParam);
	}
	break;

    default:
        FreeDDElParam(msg->message, msg->lParam);
	return WDML_QS_PASS;
    }

    return WDML_QS_HANDLED;
}
开发者ID:Moteesh,项目名称:reactos,代码行数:61,代码来源:ddeclient.c

示例5: OnDDEInitiate

LRESULT OnDDEInitiate(HWND hwnd, WPARAM wparam, LPARAM lparam)
{
    ATOM aServer = GlobalAddAtom(PDFSYNC_DDE_SERVICE);
    ATOM aTopic = GlobalAddAtom(PDFSYNC_DDE_TOPIC);

    if (LOWORD(lparam) == aServer && HIWORD(lparam) == aTopic) {
        SendMessage((HWND)wparam, WM_DDE_ACK, (WPARAM)hwnd, MAKELPARAM(aServer, 0));
    }
    else {
        GlobalDeleteAtom(aServer);
        GlobalDeleteAtom(aTopic);
    }
    return 0;
}
开发者ID:Jshauk,项目名称:sumatrapdf,代码行数:14,代码来源:Search.cpp

示例6: DDE_StartConversation

static void DDE_StartConversation(HWND hwndClientDDE, LPCSTR szApplication, LPCSTR szTopic)
{
	//static BOOL fInInitiate = FALSE; 

	ATOM atomApplication = *szApplication ? GlobalAddAtom(szApplication) : 0; 
	ATOM atomTopic       = *szTopic       ? GlobalAddAtom(szTopic      ) : 0; 

	//fInInitiate = TRUE; 
	SendMessage(HWND(-1), WM_DDE_INITIATE, WPARAM(hwndClientDDE), MAKELONG(atomApplication, atomTopic));
	//fInInitiate = FALSE; 

	if (atomApplication) GlobalDeleteAtom(atomApplication); 
	if (atomTopic      ) GlobalDeleteAtom(atomTopic      ); 
}
开发者ID:killbug2004,项目名称:WSProf,代码行数:14,代码来源:ContentHiderTHDDlg.cpp

示例7: __declspec

/* DllMain is invoked by every process in the entire system that is hooked
 * by our window hooks, notably the tty processes' context, and by the user
 * who wants tty messages (the app).  Keep it light and simple.
 */
BOOL __declspec(dllexport) APIENTRY DllMain(HINSTANCE hModule, ULONG ulReason, 
                                            LPVOID pctx)
{
    if (ulReason == DLL_PROCESS_ATTACH) 
    {
        //hmodThis = hModule;
        if (!hookwndmsg) {
            origwndprop = MAKEINTATOM(GlobalAddAtom("Win9xConHookOrigProc"));
            hookwndprop = MAKEINTATOM(GlobalAddAtom("Win9xConHookThunkWnd"));
            hookwndmsg = RegisterWindowMessage("Win9xConHookMsg");
        }
#ifdef DBG
//        DbgPrintf("H ProcessAttach:%8.8x\r\n", 
//                  GetCurrentProcessId());
#endif
    }
    else if ( ulReason == DLL_PROCESS_DETACH ) 
    {
#ifdef DBG
//        DbgPrintf("H ProcessDetach:%8.8x\r\n", GetCurrentProcessId());                
#endif
        if (monitor_hwnd)
            SendMessage(monitor_hwnd, WM_DESTROY, 0, 0);
        if (is_subclassed) 
            SendMessage(hwtty, hookwndmsg, 0, (LPARAM)hwtty);
        if (hmodHook)
        {
            if (hhkGetMessage) {
                UnhookWindowsHookEx(hhkGetMessage);
                hhkGetMessage = NULL;
            }
            //if (hhkCallWndProc) {
            //    UnhookWindowsHookEx(hhkCallWndProc);
            //    hhkCallWndProc = NULL;
            //}
            FreeLibrary(hmodHook);
            hmodHook = NULL;
        }
        if (is_service)
            RegisterWindows9xService(FALSE);
        if (hookwndmsg) {
            GlobalDeleteAtom((ATOM)origwndprop);
            GlobalDeleteAtom((ATOM)hookwndprop);
            hookwndmsg = 0;
        }
    }
    return TRUE;
}
开发者ID:Garridon,项目名称:windowsrtdev,代码行数:52,代码来源:Win9xConHook.c

示例8: _ASSERTE

bool CHotKeysToCmdRouter::UnregisterCommand(UINT i_command_id)
{
 bool result = true;
 bool is_command_exist = false;
 if (NULL==mp_OriginalWnd)
 {
  _ASSERTE(0);
  return false;
 }

 //ID-шек c кодом i_command_id в базе данных может быть больше одной, поэтому нам нужен цикл
 HotKeyMap::iterator it;
 while((it = _FindCommandID(i_command_id)) != m_hot_key_map.end()) 
 {
  is_command_exist = true;
  //нашли ID-шку в базе данных. Надо снять с регистрации горячую клавишу
  if (!UnregisterHotKey(mp_OriginalWnd->m_hWnd, (*it).first))
   result = false;
  if (GlobalDeleteAtom((*it).first) != 0)
   result = false;

  //удаляем из базы данных
  m_hot_key_map.erase(it);  
 }

 //если были ошибки или команды нет в базе данных, то возвращаем false.
 return result && is_command_exist;
}
开发者ID:fredcooke,项目名称:secu3man,代码行数:28,代码来源:HotKeysToCmdRouter.cpp

示例9: GlobalDeleteAtom

HotkeyCombo::~HotkeyCombo()
{
  if (ID)
  {
    GlobalDeleteAtom(ID);
  }
}
开发者ID:Alim-Oezdemir,项目名称:emergedesktop,代码行数:7,代码来源:HotkeyCombo.cpp

示例10: Menu_Uninstall

void Menu_Uninstall(void)
{
    ImageList_Destroy(hImageListCold);
    ImageList_Destroy(hImageListHot);
    UnhookWindowsHookEx(g_hMenuHook);
    GlobalDeleteAtom(g_hMenuAtom);
}
开发者ID:now,项目名称:slackedit,代码行数:7,代码来源:pcp_menu.c

示例11: WDML_HandlePokeReply

/******************************************************************
 *		WDML_HandlePokeReply
 *
 *
 */
static WDML_QUEUE_STATE WDML_HandlePokeReply(WDML_CONV* pConv, MSG* msg, WDML_XACT* pXAct, DWORD *ack)
{
    UINT_PTR	uiLo, uiHi;
    HSZ		hsz;

    if (msg->message != WM_DDE_ACK && WIN_GetFullHandle((HWND)msg->wParam) != pConv->hwndServer)
    {
	return WDML_QS_PASS;
    }

    UnpackDDElParam(WM_DDE_ACK, msg->lParam, &uiLo, &uiHi);
    hsz = WDML_MakeHszFromAtom(pConv->instance, uiHi);
    if (DdeCmpStringHandles(hsz, pXAct->hszItem) != 0)
    {
	return WDML_QS_PASS;
    }
    FreeDDElParam(WM_DDE_ACK, msg->lParam);
    GlobalDeleteAtom(uiHi);

    if (ack) *ack = uiLo;
    pXAct->hMem = GlobalFree(pXAct->hMem);

    pXAct->hDdeData = (HDDEDATA)TRUE;
    return TRUE;
}
开发者ID:Moteesh,项目名称:reactos,代码行数:30,代码来源:ddeclient.c

示例12: WDML_ClientQueueAdvise

/******************************************************************
 *		WDML_ClientQueueAdvise
 *
 * Creates and queue an WM_DDE_ADVISE transaction
 */
static WDML_XACT*	WDML_ClientQueueAdvise(WDML_CONV* pConv, UINT wType, UINT wFmt, HSZ hszItem)
{
    DDEADVISE*		pDdeAdvise;
    WDML_XACT*		pXAct;
    ATOM		atom;

    TRACE("XTYP_ADVSTART (with%s data) transaction\n", (wType & XTYPF_NODATA) ? "out" : "");

    atom = WDML_MakeAtomFromHsz(hszItem);
    if (!atom) return NULL;

    pXAct = WDML_AllocTransaction(pConv->instance, WM_DDE_ADVISE, wFmt, hszItem);
    if (!pXAct)
    {
	GlobalDeleteAtom(atom);
	return NULL;
    }

    pXAct->wType = wType & ~0x0F;
    pXAct->hMem = GlobalAlloc(GHND | GMEM_DDESHARE, sizeof(DDEADVISE));
    /* FIXME: hMem is unfreed for now... should be deleted in server */

    /* pack DdeAdvise	*/
    pDdeAdvise = GlobalLock(pXAct->hMem);
    pDdeAdvise->fAckReq   = (wType & XTYPF_ACKREQ) != 0;
    pDdeAdvise->fDeferUpd = (wType & XTYPF_NODATA) != 0;
    pDdeAdvise->cfFormat  = wFmt;
    GlobalUnlock(pXAct->hMem);

    pXAct->lParam = PackDDElParam(WM_DDE_ADVISE, (UINT_PTR)pXAct->hMem, atom);

    return pXAct;
}
开发者ID:Moteesh,项目名称:reactos,代码行数:38,代码来源:ddeclient.c

示例13: ps_get_monitor_timing

int ps_get_monitor_timing(int monitor_index, MonitorTiming *timing)
{
	LRESULT lresult;
	char in[256];
	
	if (!hPSWnd) return 0;
	
	lresult = SendMessage(hPSWnd, UM_GETTIMING, monitor_index, 0);
	
	if (lresult == -1)
	{
		mame_printf_verbose("PStrip: Could not get PowerStrip timing string\n");
		return 0;
	}
	
	if (!GlobalGetAtomNameA(lresult, in, sizeof(in)))
	{
		mame_printf_verbose("PStrip: GlobalGetAtomName failed\n");
		return 0;
	}
	
	mame_printf_verbose("PStrip: ps_get_monitor_timing(%d): %s\n", monitor_index, in);
	
	read_timing_string(in, timing);
	
	GlobalDeleteAtom(lresult); // delete atom created by PowerStrip

	return 1;
}
开发者ID:gustavosmk,项目名称:groovyarcade.groovymame,代码行数:29,代码来源:pstrip.c

示例14: ps_set_monitor_timing

int ps_set_monitor_timing(int monitor_index, MonitorTiming *timing)
{
	LRESULT lresult;
	ATOM atom;
	char out[256];
	
	if (!hPSWnd) return 0;
		
	fill_timing_string(out, timing);
	atom = GlobalAddAtomA(out);
	
	if (atom)
	{
		lresult = SendMessage(hPSWnd, UM_SETCUSTOMTIMING, monitor_index, atom);
		
		if (lresult < 0)
		{
			mame_printf_verbose("PStrip: SendMessage failed\n");
			GlobalDeleteAtom(atom);
		}
		else
		{
			mame_printf_verbose("PStrip: ps_set_monitor_timing(%d): %s\n", monitor_index, out);
			return 1;
		}
	}
	else mame_printf_verbose("PStrip: ps_set_monitor_timing atom creation failed\n");

	return 0;
}
开发者ID:gustavosmk,项目名称:groovyarcade.groovymame,代码行数:30,代码来源:pstrip.c

示例15: ps_create_resolution

int ps_create_resolution(int monitor_index, ModeLine *modeline)
{
	LRESULT     lresult;
	ATOM        atom;
	char        out[256];
	MonitorTiming timing = {0};
	
	if (!hPSWnd) return 0;
	
	modeline_to_pstiming(modeline, &timing);
	
	fill_timing_string(out, &timing);
	atom = GlobalAddAtomA(out);
	
	if (atom)
	{
		lresult = SendMessage(hPSWnd, UM_CREATERESOLUTION, monitor_index, atom);
		
		if (lresult < 0)
        	{
        		mame_printf_verbose("PStrip: SendMessage failed\n");
        		GlobalDeleteAtom(atom);
        	}
        	else
        	{
        		mame_printf_verbose("PStrip: ps_create_resolution(%d): %dx%d succeded \n",
        			modeline->a_width, modeline->a_height, monitor_index);
        		return 1;
        	}
        }
        else mame_printf_verbose("PStrip: ps_create_resolution atom creation failed\n");
	
	return 0;
}
开发者ID:gustavosmk,项目名称:groovyarcade.groovymame,代码行数:34,代码来源:pstrip.c


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