Skip to content

Commit

Permalink
Changed the way tLuaControl::DoVerb handles the default branch
Browse files Browse the repository at this point in the history
  • Loading branch information
nickgammon committed Sep 2, 2010
1 parent 8de0b53 commit 5896fc7
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion luacom/tLuaControl.cpp
Expand Up @@ -737,7 +737,7 @@ STDMETHODIMP tLuaControl::GetClipboardData(DWORD dwReserved, IDataObject** ppDat
STDMETHODIMP tLuaControl::DoVerb(LONG lVerb, LPMSG pMsg, IOleClientSite *pActiveSite,
LONG lIndex, HWND hwndParent, LPCRECT prcPosRect)
{
HRESULT hr = 0;
HRESULT hr = 0; // NJG - to stop warning

switch (lVerb) {
case OLEIVERB_SHOW:
Expand All @@ -755,6 +755,11 @@ STDMETHODIMP tLuaControl::DoVerb(LONG lVerb, LPMSG pMsg, IOleClientSite *pActive
// if it's a derived-control defined verb, pass it on to them
//
if (lVerb > 0) {

// FIX-TODO!!! hr is undefined here.
// http://lua-users.org/lists/lua-l/2006-09/msg00030.html
FAIL("FIX - luacom bug lua-l/2006-09/msg00030.html");

if (hr == OLEOBJ_S_INVALIDVERB) {
// unrecognised verb -- just do the primary verb and
// activate the sucker.
Expand Down

0 comments on commit 5896fc7

Please sign in to comment.