Author Topic: [ Patch #1005 ] typo-fix in menuutils.cpp of keybinder plugin in rev2370  (Read 2899 times)

Offline TheTuxKeeper

  • Regular
  • ***
  • Posts: 293
  • daniel2000
The error when compiling the keybinder plugin is:
Code: [Select]
ccache g++ -DHAVE_CONFIG_H -I. -I. -I../../../../src/sdk -I/usr/lib/wx/include/gtk2-unicode-release-2.6 -I/usr/include/wx-2.6 -DGTK_NO_CHECK_CASTS -D__WXGTK__ -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D_LARGEFILE_SOURCE=1 -DNO_GCC_PRAGMA -I../../../../src/sdk -I../../../../src/sdk/wxscintilla/include -I/usr/lib/wx/include/gtk2-unicode-release-2.6 -I/usr/include/wx-2.6 -DGTK_NO_CHECK_CASTS -D__WXGTK__ -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D_LARGEFILE_SOURCE=1 -DNO_GCC_PRAGMA -g -DDEBUG -O2 -g -march=i686 -mtune=i686 -I/usr/lib/wx/include/gtk2-unicode-release-2.6 -I/usr/include/wx-2.6 -DGTK_NO_CHECK_CASTS -D__WXGTK__ -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D_LARGEFILE_SOURCE=1 -DNO_GCC_PRAGMA -DCB_PRECOMP -Winvalid-pch -fPIC -DPIC -MT menuutils.lo -MD -MP -MF .deps/menuutils.Tpo -c menuutils.cpp  -fPIC -DPIC -o .libs/menuutils.o
menuutils.cpp: In member function 'virtual void wxMenuCmd::Update(wxMenuItem*)':
menuutils.cpp:95: error: 'pLclMenuItem' was not declared in this scope

I think I found the typo, during writing this and inspecting the diff to rev2369 :D
Should it be pLclMnuItem instead of pLclMenuItem ? Yes, it should ;)

There are only two lines with this typo:
Code: [Select]
./src/plugins/contrib/keybinder/menuutils.cpp:95:       wxString str = pLclMenuItem->GetLabel();
./src/plugins/contrib/keybinder/menuutils.cpp:112:              pLclMenuItem->SetText(str);

Yeah it compiles without any error :-D
I searched through the whole cb-sources and include files (/usr/include) to find pLclMenuItem. Now I know why I wasn't able to find it :lol:

EDIT: I submitted the huge patch #1005 :lol: This fixes this error.
« Last Edit: April 23, 2006, 09:56:59 pm by daniel2000 »
Nightly builds for openSUSE

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2150
There are only two lines with this typo:
Code: [Select]
./src/plugins/contrib/keybinder/menuutils.cpp:95:       wxString str = pLclMenuItem->GetLabel();
./src/plugins/contrib/keybinder/menuutils.cpp:112:              pLclMenuItem->SetText(str);

Thank you.

That's what I get for testing on Linux, but commiting from Windows.

thanks
pecan
« Last Edit: April 23, 2006, 10:19:41 pm by Pecan »

Offline TheTuxKeeper

  • Regular
  • ***
  • Posts: 293
  • daniel2000
There are only two lines with this typo:
Code: [Select]
./src/plugins/contrib/keybinder/menuutils.cpp:95:       wxString str = pLclMenuItem->GetLabel();
./src/plugins/contrib/keybinder/menuutils.cpp:112:              pLclMenuItem->SetText(str);

Thank you.

That's what I get for testing on Linux, but commiting from Windows.

thanks
pecan

Lieven also wrote something about wxGTK-specific and now I also recognized it. There's a "#ifdef __WXGTK__"  before :!:
Now I understand it.  8)
Wow, seems to be really hard to code OS-independent even if you have a toolkit which should make it easier.
Nightly builds for openSUSE