CWinAppEx::InitContextMenuManager

更新 : 2007 年 11 月

CContextMenuManager オブジェクトを初期化します。

BOOL InitContextMenuManager();

戻り値

メソッドが CContextMenuManager オブジェクトを作成する場合は 0 以外。CContextMenuManager オブジェクトが既に存在する場合は 0。

解説

CWinAppEx::GetContextMenuManager を呼び出すと、そのメソッドの既定の実装は InitContextMenuManager を呼び出します。

アプリケーションに既にコンテキスト メニュー マネージャがある場合は、InitContextMenuManager を呼び出すと、アプリケーションで ASSERT エラーが発生します。したがって、CContextMenuManager オブジェクトを直接作成する場合は、InitContextMenuManager を呼び出さないでください。カスタム CContextMenuManager を使用していない場合は、GetContextMenuManager を使用して CContextMenuManager オブジェクトを作成する必要があります。

必要条件

ヘッダー : afxwinappex.h

参照

概念

MFC 階層図

参照

CWinAppEx クラス

CWinAppEx::GetContextMenuManager

CContextMenuManager クラス