From b815cf68d24508ab76ace1ef439a6d4feffbd487 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 17 Aug 2010 16:55:32 +0000 Subject: [PATCH] Provide native wxHyperlinkCtrl implementation for wxMSW. Use the "syslink" native control to implement wxHyperlinkCtrl under (recent enough, i.e. XP or later) versions of Windows. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65334 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- Makefile.in | 50 ++++++++-- build/bakefiles/files.bkl | 2 + build/msw/makefile.bcc | 24 +++++ build/msw/makefile.gcc | 24 +++++ build/msw/makefile.vc | 24 +++++ build/msw/makefile.wat | 24 +++++ build/msw/wx_adv.dsp | 8 ++ build/msw/wx_core.dsp | 4 + build/msw/wx_vc7_adv.vcproj | 6 ++ build/msw/wx_vc7_core.vcproj | 3 + build/msw/wx_vc8_adv.vcproj | 8 ++ build/msw/wx_vc8_core.vcproj | 4 + build/msw/wx_vc9_adv.vcproj | 8 ++ build/msw/wx_vc9_core.vcproj | 4 + docs/changes.txt | 1 + include/wx/generic/hyperlink.h | 17 ++-- include/wx/hyperlink.h | 25 ++++- include/wx/msw/hyperlink.h | 65 +++++++++++++ interface/wx/hyperlink.h | 10 +- src/common/hyperlnkcmn.cpp | 6 ++ src/generic/hyperlinkg.cpp | 44 +++++---- src/gtk/hyperlink.cpp | 3 - src/msw/hyperlink.cpp | 172 +++++++++++++++++++++++++++++++++ 23 files changed, 495 insertions(+), 41 deletions(-) create mode 100644 include/wx/msw/hyperlink.h create mode 100644 src/msw/hyperlink.cpp diff --git a/Makefile.in b/Makefile.in index b11b273493..c578633026 100644 --- a/Makefile.in +++ b/Makefile.in @@ -3577,6 +3577,7 @@ COND_TOOLKIT_MOTIF_ADVANCED_PLATFORM_HDR = \ @COND_TOOLKIT_MOTIF@ADVANCED_PLATFORM_HDR = $(COND_TOOLKIT_MOTIF_ADVANCED_PLATFORM_HDR) COND_TOOLKIT_MSW_ADVANCED_PLATFORM_HDR = \ wx/msw/commandlinkbutton.h \ + wx/msw/hyperlink.h \ wx/msw/notifmsg.h \ wx/msw/sound.h \ wx/msw/taskbar.h \ @@ -3611,6 +3612,7 @@ COND_TOOLKIT_OSX_COCOA_ADVANCED_PLATFORM_HDR = \ @COND_TOOLKIT_PM@ wx/generic/animate.h wx/os2/joystick.h wx/os2/sound.h COND_TOOLKIT_WINCE_ADVANCED_PLATFORM_HDR = \ wx/msw/commandlinkbutton.h \ + wx/msw/hyperlink.h \ wx/msw/notifmsg.h \ wx/msw/sound.h \ wx/msw/taskbar.h @@ -6009,7 +6011,7 @@ COND_TOOLKIT_GTK_TOOLKIT_VERSION_2___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS = \ monodll_gtk_bmpcbox.o \ monodll_gtk_calctrl.o \ monodll_gtk_dataview.o \ - monodll_hyperlink.o + monodll_gtk_hyperlink.o @COND_TOOLKIT_GTK_TOOLKIT_VERSION_2@__ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS = $(COND_TOOLKIT_GTK_TOOLKIT_VERSION_2___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS) COND_TOOLKIT_MSW___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS = \ monodll_animateg.o \ @@ -7879,7 +7881,7 @@ COND_TOOLKIT_GTK_TOOLKIT_VERSION_2___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_1 = \ monolib_gtk_bmpcbox.o \ monolib_gtk_calctrl.o \ monolib_gtk_dataview.o \ - monolib_hyperlink.o + monolib_gtk_hyperlink.o @COND_TOOLKIT_GTK_TOOLKIT_VERSION_2@__ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_1 = $(COND_TOOLKIT_GTK_TOOLKIT_VERSION_2___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_1) COND_TOOLKIT_MSW___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_1 = \ monolib_animateg.o \ @@ -11546,7 +11548,7 @@ COND_TOOLKIT_GTK_TOOLKIT_VERSION_2___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_2 = \ advdll_gtk_bmpcbox.o \ advdll_gtk_calctrl.o \ advdll_gtk_dataview.o \ - advdll_hyperlink.o + advdll_gtk_hyperlink.o @COND_TOOLKIT_GTK_TOOLKIT_VERSION_2@__ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_2 = $(COND_TOOLKIT_GTK_TOOLKIT_VERSION_2___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_2) COND_TOOLKIT_MSW___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_2 = \ advdll_animateg.o \ @@ -11642,7 +11644,7 @@ COND_TOOLKIT_GTK_TOOLKIT_VERSION_2___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_3 = \ advlib_gtk_bmpcbox.o \ advlib_gtk_calctrl.o \ advlib_gtk_dataview.o \ - advlib_hyperlink.o + advlib_gtk_hyperlink.o @COND_TOOLKIT_GTK_TOOLKIT_VERSION_2@__ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_3 = $(COND_TOOLKIT_GTK_TOOLKIT_VERSION_2___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_3) COND_TOOLKIT_MSW___ADVANCED_PLATFORM_NATIVE_SRC_OBJECTS_3 = \ advlib_animateg.o \ @@ -12805,6 +12807,7 @@ COND_TOOLKIT_MSW___ADVANCED_PLATFORM_SRC_OBJECTS = \ monodll_taskbarcmn.o \ monodll_msw_aboutdlg.o \ monodll_commandlinkbutton.o \ + monodll_msw_hyperlink.o \ monodll_msw_notifmsg.o \ monodll_msw_sound.o \ monodll_msw_taskbar.o \ @@ -12844,6 +12847,7 @@ COND_TOOLKIT_WINCE___ADVANCED_PLATFORM_SRC_OBJECTS = \ monodll_taskbarcmn.o \ monodll_msw_aboutdlg.o \ monodll_commandlinkbutton.o \ + monodll_msw_hyperlink.o \ monodll_msw_notifmsg.o \ monodll_msw_sound.o \ monodll_msw_taskbar.o @@ -12992,6 +12996,7 @@ COND_TOOLKIT_MSW___ADVANCED_PLATFORM_SRC_OBJECTS_0 = \ monolib_taskbarcmn.o \ monolib_msw_aboutdlg.o \ monolib_commandlinkbutton.o \ + monolib_msw_hyperlink.o \ monolib_msw_notifmsg.o \ monolib_msw_sound.o \ monolib_msw_taskbar.o \ @@ -13031,6 +13036,7 @@ COND_TOOLKIT_WINCE___ADVANCED_PLATFORM_SRC_OBJECTS_0 = \ monolib_taskbarcmn.o \ monolib_msw_aboutdlg.o \ monolib_commandlinkbutton.o \ + monolib_msw_hyperlink.o \ monolib_msw_notifmsg.o \ monolib_msw_sound.o \ monolib_msw_taskbar.o @@ -13276,6 +13282,7 @@ COND_TOOLKIT_MSW___ADVANCED_PLATFORM_SRC_OBJECTS_8 = \ advdll_taskbarcmn.o \ advdll_msw_aboutdlg.o \ advdll_commandlinkbutton.o \ + advdll_msw_hyperlink.o \ advdll_msw_notifmsg.o \ advdll_msw_sound.o \ advdll_msw_taskbar.o \ @@ -13315,6 +13322,7 @@ COND_TOOLKIT_WINCE___ADVANCED_PLATFORM_SRC_OBJECTS_8 = \ advdll_taskbarcmn.o \ advdll_msw_aboutdlg.o \ advdll_commandlinkbutton.o \ + advdll_msw_hyperlink.o \ advdll_msw_notifmsg.o \ advdll_msw_sound.o \ advdll_msw_taskbar.o @@ -13366,6 +13374,7 @@ COND_TOOLKIT_MSW___ADVANCED_PLATFORM_SRC_OBJECTS_9 = \ advlib_taskbarcmn.o \ advlib_msw_aboutdlg.o \ advlib_commandlinkbutton.o \ + advlib_msw_hyperlink.o \ advlib_msw_notifmsg.o \ advlib_msw_sound.o \ advlib_msw_taskbar.o \ @@ -13405,6 +13414,7 @@ COND_TOOLKIT_WINCE___ADVANCED_PLATFORM_SRC_OBJECTS_9 = \ advlib_taskbarcmn.o \ advlib_msw_aboutdlg.o \ advlib_commandlinkbutton.o \ + advlib_msw_hyperlink.o \ advlib_msw_notifmsg.o \ advlib_msw_sound.o \ advlib_msw_taskbar.o @@ -16745,7 +16755,7 @@ monodll_gtk_calctrl.o: $(srcdir)/src/gtk/calctrl.cpp $(MONODLL_ODEP) monodll_gtk_dataview.o: $(srcdir)/src/gtk/dataview.cpp $(MONODLL_ODEP) $(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/gtk/dataview.cpp -monodll_hyperlink.o: $(srcdir)/src/gtk/hyperlink.cpp $(MONODLL_ODEP) +monodll_gtk_hyperlink.o: $(srcdir)/src/gtk/hyperlink.cpp $(MONODLL_ODEP) $(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/gtk/hyperlink.cpp monodll_mediactrlcmn.o: $(srcdir)/src/common/mediactrlcmn.cpp $(MONODLL_ODEP) @@ -20039,6 +20049,12 @@ monodll_sound_sdl.o: $(srcdir)/src/unix/sound_sdl.cpp $(MONODLL_ODEP) @COND_TOOLKIT_WINCE_USE_GUI_1@monodll_commandlinkbutton.o: $(srcdir)/src/msw/commandlinkbutton.cpp $(MONODLL_ODEP) @COND_TOOLKIT_WINCE_USE_GUI_1@ $(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/msw/commandlinkbutton.cpp +@COND_TOOLKIT_MSW_USE_GUI_1@monodll_msw_hyperlink.o: $(srcdir)/src/msw/hyperlink.cpp $(MONODLL_ODEP) +@COND_TOOLKIT_MSW_USE_GUI_1@ $(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/msw/hyperlink.cpp + +@COND_TOOLKIT_WINCE_USE_GUI_1@monodll_msw_hyperlink.o: $(srcdir)/src/msw/hyperlink.cpp $(MONODLL_ODEP) +@COND_TOOLKIT_WINCE_USE_GUI_1@ $(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/msw/hyperlink.cpp + @COND_TOOLKIT_MSW_USE_GUI_1@monodll_msw_notifmsg.o: $(srcdir)/src/msw/notifmsg.cpp $(MONODLL_ODEP) @COND_TOOLKIT_MSW_USE_GUI_1@ $(CXXC) -c -o $@ $(MONODLL_CXXFLAGS) $(srcdir)/src/msw/notifmsg.cpp @@ -21956,7 +21972,7 @@ monolib_gtk_calctrl.o: $(srcdir)/src/gtk/calctrl.cpp $(MONOLIB_ODEP) monolib_gtk_dataview.o: $(srcdir)/src/gtk/dataview.cpp $(MONOLIB_ODEP) $(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/gtk/dataview.cpp -monolib_hyperlink.o: $(srcdir)/src/gtk/hyperlink.cpp $(MONOLIB_ODEP) +monolib_gtk_hyperlink.o: $(srcdir)/src/gtk/hyperlink.cpp $(MONOLIB_ODEP) $(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/gtk/hyperlink.cpp monolib_mediactrlcmn.o: $(srcdir)/src/common/mediactrlcmn.cpp $(MONOLIB_ODEP) @@ -25250,6 +25266,12 @@ monolib_sound_sdl.o: $(srcdir)/src/unix/sound_sdl.cpp $(MONOLIB_ODEP) @COND_TOOLKIT_WINCE_USE_GUI_1@monolib_commandlinkbutton.o: $(srcdir)/src/msw/commandlinkbutton.cpp $(MONOLIB_ODEP) @COND_TOOLKIT_WINCE_USE_GUI_1@ $(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/msw/commandlinkbutton.cpp +@COND_TOOLKIT_MSW_USE_GUI_1@monolib_msw_hyperlink.o: $(srcdir)/src/msw/hyperlink.cpp $(MONOLIB_ODEP) +@COND_TOOLKIT_MSW_USE_GUI_1@ $(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/msw/hyperlink.cpp + +@COND_TOOLKIT_WINCE_USE_GUI_1@monolib_msw_hyperlink.o: $(srcdir)/src/msw/hyperlink.cpp $(MONOLIB_ODEP) +@COND_TOOLKIT_WINCE_USE_GUI_1@ $(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/msw/hyperlink.cpp + @COND_TOOLKIT_MSW_USE_GUI_1@monolib_msw_notifmsg.o: $(srcdir)/src/msw/notifmsg.cpp $(MONOLIB_ODEP) @COND_TOOLKIT_MSW_USE_GUI_1@ $(CXXC) -c -o $@ $(MONOLIB_CXXFLAGS) $(srcdir)/src/msw/notifmsg.cpp @@ -34463,7 +34485,7 @@ advdll_gtk_calctrl.o: $(srcdir)/src/gtk/calctrl.cpp $(ADVDLL_ODEP) advdll_gtk_dataview.o: $(srcdir)/src/gtk/dataview.cpp $(ADVDLL_ODEP) $(CXXC) -c -o $@ $(ADVDLL_CXXFLAGS) $(srcdir)/src/gtk/dataview.cpp -advdll_hyperlink.o: $(srcdir)/src/gtk/hyperlink.cpp $(ADVDLL_ODEP) +advdll_gtk_hyperlink.o: $(srcdir)/src/gtk/hyperlink.cpp $(ADVDLL_ODEP) $(CXXC) -c -o $@ $(ADVDLL_CXXFLAGS) $(srcdir)/src/gtk/hyperlink.cpp advdll_sound_sdl.o: $(srcdir)/src/unix/sound_sdl.cpp $(ADVDLL_ODEP) @@ -34589,6 +34611,12 @@ advdll_wizard.o: $(srcdir)/src/generic/wizard.cpp $(ADVDLL_ODEP) @COND_TOOLKIT_WINCE@advdll_commandlinkbutton.o: $(srcdir)/src/msw/commandlinkbutton.cpp $(ADVDLL_ODEP) @COND_TOOLKIT_WINCE@ $(CXXC) -c -o $@ $(ADVDLL_CXXFLAGS) $(srcdir)/src/msw/commandlinkbutton.cpp +@COND_TOOLKIT_MSW@advdll_msw_hyperlink.o: $(srcdir)/src/msw/hyperlink.cpp $(ADVDLL_ODEP) +@COND_TOOLKIT_MSW@ $(CXXC) -c -o $@ $(ADVDLL_CXXFLAGS) $(srcdir)/src/msw/hyperlink.cpp + +@COND_TOOLKIT_WINCE@advdll_msw_hyperlink.o: $(srcdir)/src/msw/hyperlink.cpp $(ADVDLL_ODEP) +@COND_TOOLKIT_WINCE@ $(CXXC) -c -o $@ $(ADVDLL_CXXFLAGS) $(srcdir)/src/msw/hyperlink.cpp + @COND_TOOLKIT_MSW@advdll_msw_notifmsg.o: $(srcdir)/src/msw/notifmsg.cpp $(ADVDLL_ODEP) @COND_TOOLKIT_MSW@ $(CXXC) -c -o $@ $(ADVDLL_CXXFLAGS) $(srcdir)/src/msw/notifmsg.cpp @@ -34805,7 +34833,7 @@ advlib_gtk_calctrl.o: $(srcdir)/src/gtk/calctrl.cpp $(ADVLIB_ODEP) advlib_gtk_dataview.o: $(srcdir)/src/gtk/dataview.cpp $(ADVLIB_ODEP) $(CXXC) -c -o $@ $(ADVLIB_CXXFLAGS) $(srcdir)/src/gtk/dataview.cpp -advlib_hyperlink.o: $(srcdir)/src/gtk/hyperlink.cpp $(ADVLIB_ODEP) +advlib_gtk_hyperlink.o: $(srcdir)/src/gtk/hyperlink.cpp $(ADVLIB_ODEP) $(CXXC) -c -o $@ $(ADVLIB_CXXFLAGS) $(srcdir)/src/gtk/hyperlink.cpp advlib_sound_sdl.o: $(srcdir)/src/unix/sound_sdl.cpp $(ADVLIB_ODEP) @@ -34931,6 +34959,12 @@ advlib_wizard.o: $(srcdir)/src/generic/wizard.cpp $(ADVLIB_ODEP) @COND_TOOLKIT_WINCE@advlib_commandlinkbutton.o: $(srcdir)/src/msw/commandlinkbutton.cpp $(ADVLIB_ODEP) @COND_TOOLKIT_WINCE@ $(CXXC) -c -o $@ $(ADVLIB_CXXFLAGS) $(srcdir)/src/msw/commandlinkbutton.cpp +@COND_TOOLKIT_MSW@advlib_msw_hyperlink.o: $(srcdir)/src/msw/hyperlink.cpp $(ADVLIB_ODEP) +@COND_TOOLKIT_MSW@ $(CXXC) -c -o $@ $(ADVLIB_CXXFLAGS) $(srcdir)/src/msw/hyperlink.cpp + +@COND_TOOLKIT_WINCE@advlib_msw_hyperlink.o: $(srcdir)/src/msw/hyperlink.cpp $(ADVLIB_ODEP) +@COND_TOOLKIT_WINCE@ $(CXXC) -c -o $@ $(ADVLIB_CXXFLAGS) $(srcdir)/src/msw/hyperlink.cpp + @COND_TOOLKIT_MSW@advlib_msw_notifmsg.o: $(srcdir)/src/msw/notifmsg.cpp $(ADVLIB_ODEP) @COND_TOOLKIT_MSW@ $(CXXC) -c -o $@ $(ADVLIB_CXXFLAGS) $(srcdir)/src/msw/notifmsg.cpp diff --git a/build/bakefiles/files.bkl b/build/bakefiles/files.bkl index 1984a8d064..93848a08b3 100644 --- a/build/bakefiles/files.bkl +++ b/build/bakefiles/files.bkl @@ -2969,12 +2969,14 @@ IMPORTANT: please read docs/tech/tn0016.txt before modifying this file! src/common/taskbarcmn.cpp src/msw/aboutdlg.cpp src/msw/commandlinkbutton.cpp + src/msw/hyperlink.cpp src/msw/notifmsg.cpp src/msw/sound.cpp src/msw/taskbar.cpp wx/msw/commandlinkbutton.h + wx/msw/hyperlink.h wx/msw/notifmsg.h wx/msw/sound.h wx/msw/taskbar.h diff --git a/build/msw/makefile.bcc b/build/msw/makefile.bcc index aea7565c45..f79ae2cdf4 100644 --- a/build/msw/makefile.bcc +++ b/build/msw/makefile.bcc @@ -2191,6 +2191,7 @@ ____ADVANCED_SRC_FILENAMES_OBJECTS = \ $(OBJS)\monodll_taskbarcmn.obj \ $(OBJS)\monodll_aboutdlg.obj \ $(OBJS)\monodll_commandlinkbutton.obj \ + $(OBJS)\monodll_hyperlink.obj \ $(OBJS)\monodll_notifmsg.obj \ $(OBJS)\monodll_sound.obj \ $(OBJS)\monodll_taskbar.obj \ @@ -2232,6 +2233,7 @@ ____ADVANCED_SRC_FILENAMES_OBJECTS = \ $(OBJS)\monodll_taskbarcmn.obj \ $(OBJS)\monodll_aboutdlg.obj \ $(OBJS)\monodll_commandlinkbutton.obj \ + $(OBJS)\monodll_hyperlink.obj \ $(OBJS)\monodll_notifmsg.obj \ $(OBJS)\monodll_sound.obj \ $(OBJS)\monodll_taskbar.obj \ @@ -2904,6 +2906,7 @@ ____ADVANCED_SRC_FILENAMES_1_OBJECTS = \ $(OBJS)\monolib_taskbarcmn.obj \ $(OBJS)\monolib_aboutdlg.obj \ $(OBJS)\monolib_commandlinkbutton.obj \ + $(OBJS)\monolib_hyperlink.obj \ $(OBJS)\monolib_notifmsg.obj \ $(OBJS)\monolib_sound.obj \ $(OBJS)\monolib_taskbar.obj \ @@ -2945,6 +2948,7 @@ ____ADVANCED_SRC_FILENAMES_1_OBJECTS = \ $(OBJS)\monolib_taskbarcmn.obj \ $(OBJS)\monolib_aboutdlg.obj \ $(OBJS)\monolib_commandlinkbutton.obj \ + $(OBJS)\monolib_hyperlink.obj \ $(OBJS)\monolib_notifmsg.obj \ $(OBJS)\monolib_sound.obj \ $(OBJS)\monolib_taskbar.obj \ @@ -4016,6 +4020,7 @@ ____ADVANCED_SRC_FILENAMES_2_OBJECTS = \ $(OBJS)\advdll_taskbarcmn.obj \ $(OBJS)\advdll_aboutdlg.obj \ $(OBJS)\advdll_commandlinkbutton.obj \ + $(OBJS)\advdll_hyperlink.obj \ $(OBJS)\advdll_notifmsg.obj \ $(OBJS)\advdll_sound.obj \ $(OBJS)\advdll_taskbar.obj \ @@ -4057,6 +4062,7 @@ ____ADVANCED_SRC_FILENAMES_2_OBJECTS = \ $(OBJS)\advdll_taskbarcmn.obj \ $(OBJS)\advdll_aboutdlg.obj \ $(OBJS)\advdll_commandlinkbutton.obj \ + $(OBJS)\advdll_hyperlink.obj \ $(OBJS)\advdll_notifmsg.obj \ $(OBJS)\advdll_sound.obj \ $(OBJS)\advdll_taskbar.obj \ @@ -4098,6 +4104,7 @@ ____ADVANCED_SRC_FILENAMES_3_OBJECTS = \ $(OBJS)\advlib_taskbarcmn.obj \ $(OBJS)\advlib_aboutdlg.obj \ $(OBJS)\advlib_commandlinkbutton.obj \ + $(OBJS)\advlib_hyperlink.obj \ $(OBJS)\advlib_notifmsg.obj \ $(OBJS)\advlib_sound.obj \ $(OBJS)\advlib_taskbar.obj \ @@ -4139,6 +4146,7 @@ ____ADVANCED_SRC_FILENAMES_3_OBJECTS = \ $(OBJS)\advlib_taskbarcmn.obj \ $(OBJS)\advlib_aboutdlg.obj \ $(OBJS)\advlib_commandlinkbutton.obj \ + $(OBJS)\advlib_hyperlink.obj \ $(OBJS)\advlib_notifmsg.obj \ $(OBJS)\advlib_sound.obj \ $(OBJS)\advlib_taskbar.obj \ @@ -7891,6 +7899,11 @@ $(OBJS)\monodll_commandlinkbutton.obj: ..\..\src\msw\commandlinkbutton.cpp $(CXX) -q -c -P -o$@ $(MONODLL_CXXFLAGS) ..\..\src\msw\commandlinkbutton.cpp !endif +!if "$(USE_GUI)" == "1" +$(OBJS)\monodll_hyperlink.obj: ..\..\src\msw\hyperlink.cpp + $(CXX) -q -c -P -o$@ $(MONODLL_CXXFLAGS) ..\..\src\msw\hyperlink.cpp +!endif + !if "$(USE_GUI)" == "1" $(OBJS)\monodll_notifmsg.obj: ..\..\src\msw\notifmsg.cpp $(CXX) -q -c -P -o$@ $(MONODLL_CXXFLAGS) ..\..\src\msw\notifmsg.cpp @@ -10108,6 +10121,11 @@ $(OBJS)\monolib_commandlinkbutton.obj: ..\..\src\msw\commandlinkbutton.cpp $(CXX) -q -c -P -o$@ $(MONOLIB_CXXFLAGS) ..\..\src\msw\commandlinkbutton.cpp !endif +!if "$(USE_GUI)" == "1" +$(OBJS)\monolib_hyperlink.obj: ..\..\src\msw\hyperlink.cpp + $(CXX) -q -c -P -o$@ $(MONOLIB_CXXFLAGS) ..\..\src\msw\hyperlink.cpp +!endif + !if "$(USE_GUI)" == "1" $(OBJS)\monolib_notifmsg.obj: ..\..\src\msw\notifmsg.cpp $(CXX) -q -c -P -o$@ $(MONOLIB_CXXFLAGS) ..\..\src\msw\notifmsg.cpp @@ -13585,6 +13603,9 @@ $(OBJS)\advdll_aboutdlg.obj: ..\..\src\msw\aboutdlg.cpp $(OBJS)\advdll_commandlinkbutton.obj: ..\..\src\msw\commandlinkbutton.cpp $(CXX) -q -c -P -o$@ $(ADVDLL_CXXFLAGS) ..\..\src\msw\commandlinkbutton.cpp +$(OBJS)\advdll_hyperlink.obj: ..\..\src\msw\hyperlink.cpp + $(CXX) -q -c -P -o$@ $(ADVDLL_CXXFLAGS) ..\..\src\msw\hyperlink.cpp + $(OBJS)\advdll_notifmsg.obj: ..\..\src\msw\notifmsg.cpp $(CXX) -q -c -P -o$@ $(ADVDLL_CXXFLAGS) ..\..\src\msw\notifmsg.cpp @@ -13702,6 +13723,9 @@ $(OBJS)\advlib_aboutdlg.obj: ..\..\src\msw\aboutdlg.cpp $(OBJS)\advlib_commandlinkbutton.obj: ..\..\src\msw\commandlinkbutton.cpp $(CXX) -q -c -P -o$@ $(ADVLIB_CXXFLAGS) ..\..\src\msw\commandlinkbutton.cpp +$(OBJS)\advlib_hyperlink.obj: ..\..\src\msw\hyperlink.cpp + $(CXX) -q -c -P -o$@ $(ADVLIB_CXXFLAGS) ..\..\src\msw\hyperlink.cpp + $(OBJS)\advlib_notifmsg.obj: ..\..\src\msw\notifmsg.cpp $(CXX) -q -c -P -o$@ $(ADVLIB_CXXFLAGS) ..\..\src\msw\notifmsg.cpp diff --git a/build/msw/makefile.gcc b/build/msw/makefile.gcc index d5db1c952f..460e3a1ba8 100644 --- a/build/msw/makefile.gcc +++ b/build/msw/makefile.gcc @@ -2205,6 +2205,7 @@ ____ADVANCED_SRC_FILENAMES_OBJECTS = \ $(OBJS)\monodll_taskbarcmn.o \ $(OBJS)\monodll_aboutdlg.o \ $(OBJS)\monodll_commandlinkbutton.o \ + $(OBJS)\monodll_hyperlink.o \ $(OBJS)\monodll_notifmsg.o \ $(OBJS)\monodll_sound.o \ $(OBJS)\monodll_taskbar.o \ @@ -2246,6 +2247,7 @@ ____ADVANCED_SRC_FILENAMES_OBJECTS = \ $(OBJS)\monodll_taskbarcmn.o \ $(OBJS)\monodll_aboutdlg.o \ $(OBJS)\monodll_commandlinkbutton.o \ + $(OBJS)\monodll_hyperlink.o \ $(OBJS)\monodll_notifmsg.o \ $(OBJS)\monodll_sound.o \ $(OBJS)\monodll_taskbar.o \ @@ -2924,6 +2926,7 @@ ____ADVANCED_SRC_FILENAMES_1_OBJECTS = \ $(OBJS)\monolib_taskbarcmn.o \ $(OBJS)\monolib_aboutdlg.o \ $(OBJS)\monolib_commandlinkbutton.o \ + $(OBJS)\monolib_hyperlink.o \ $(OBJS)\monolib_notifmsg.o \ $(OBJS)\monolib_sound.o \ $(OBJS)\monolib_taskbar.o \ @@ -2965,6 +2968,7 @@ ____ADVANCED_SRC_FILENAMES_1_OBJECTS = \ $(OBJS)\monolib_taskbarcmn.o \ $(OBJS)\monolib_aboutdlg.o \ $(OBJS)\monolib_commandlinkbutton.o \ + $(OBJS)\monolib_hyperlink.o \ $(OBJS)\monolib_notifmsg.o \ $(OBJS)\monolib_sound.o \ $(OBJS)\monolib_taskbar.o \ @@ -4064,6 +4068,7 @@ ____ADVANCED_SRC_FILENAMES_2_OBJECTS = \ $(OBJS)\advdll_taskbarcmn.o \ $(OBJS)\advdll_aboutdlg.o \ $(OBJS)\advdll_commandlinkbutton.o \ + $(OBJS)\advdll_hyperlink.o \ $(OBJS)\advdll_notifmsg.o \ $(OBJS)\advdll_sound.o \ $(OBJS)\advdll_taskbar.o \ @@ -4105,6 +4110,7 @@ ____ADVANCED_SRC_FILENAMES_2_OBJECTS = \ $(OBJS)\advdll_taskbarcmn.o \ $(OBJS)\advdll_aboutdlg.o \ $(OBJS)\advdll_commandlinkbutton.o \ + $(OBJS)\advdll_hyperlink.o \ $(OBJS)\advdll_notifmsg.o \ $(OBJS)\advdll_sound.o \ $(OBJS)\advdll_taskbar.o \ @@ -4150,6 +4156,7 @@ ____ADVANCED_SRC_FILENAMES_3_OBJECTS = \ $(OBJS)\advlib_taskbarcmn.o \ $(OBJS)\advlib_aboutdlg.o \ $(OBJS)\advlib_commandlinkbutton.o \ + $(OBJS)\advlib_hyperlink.o \ $(OBJS)\advlib_notifmsg.o \ $(OBJS)\advlib_sound.o \ $(OBJS)\advlib_taskbar.o \ @@ -4191,6 +4198,7 @@ ____ADVANCED_SRC_FILENAMES_3_OBJECTS = \ $(OBJS)\advlib_taskbarcmn.o \ $(OBJS)\advlib_aboutdlg.o \ $(OBJS)\advlib_commandlinkbutton.o \ + $(OBJS)\advlib_hyperlink.o \ $(OBJS)\advlib_notifmsg.o \ $(OBJS)\advlib_sound.o \ $(OBJS)\advlib_taskbar.o \ @@ -8041,6 +8049,11 @@ $(OBJS)\monodll_commandlinkbutton.o: ../../src/msw/commandlinkbutton.cpp $(CXX) -c -o $@ $(MONODLL_CXXFLAGS) $(CPPDEPS) $< endif +ifeq ($(USE_GUI),1) +$(OBJS)\monodll_hyperlink.o: ../../src/msw/hyperlink.cpp + $(CXX) -c -o $@ $(MONODLL_CXXFLAGS) $(CPPDEPS) $< +endif + ifeq ($(USE_GUI),1) $(OBJS)\monodll_notifmsg.o: ../../src/msw/notifmsg.cpp $(CXX) -c -o $@ $(MONODLL_CXXFLAGS) $(CPPDEPS) $< @@ -10258,6 +10271,11 @@ $(OBJS)\monolib_commandlinkbutton.o: ../../src/msw/commandlinkbutton.cpp $(CXX) -c -o $@ $(MONOLIB_CXXFLAGS) $(CPPDEPS) $< endif +ifeq ($(USE_GUI),1) +$(OBJS)\monolib_hyperlink.o: ../../src/msw/hyperlink.cpp + $(CXX) -c -o $@ $(MONOLIB_CXXFLAGS) $(CPPDEPS) $< +endif + ifeq ($(USE_GUI),1) $(OBJS)\monolib_notifmsg.o: ../../src/msw/notifmsg.cpp $(CXX) -c -o $@ $(MONOLIB_CXXFLAGS) $(CPPDEPS) $< @@ -13735,6 +13753,9 @@ $(OBJS)\advdll_aboutdlg.o: ../../src/msw/aboutdlg.cpp $(OBJS)\advdll_commandlinkbutton.o: ../../src/msw/commandlinkbutton.cpp $(CXX) -c -o $@ $(ADVDLL_CXXFLAGS) $(CPPDEPS) $< +$(OBJS)\advdll_hyperlink.o: ../../src/msw/hyperlink.cpp + $(CXX) -c -o $@ $(ADVDLL_CXXFLAGS) $(CPPDEPS) $< + $(OBJS)\advdll_notifmsg.o: ../../src/msw/notifmsg.cpp $(CXX) -c -o $@ $(ADVDLL_CXXFLAGS) $(CPPDEPS) $< @@ -13852,6 +13873,9 @@ $(OBJS)\advlib_aboutdlg.o: ../../src/msw/aboutdlg.cpp $(OBJS)\advlib_commandlinkbutton.o: ../../src/msw/commandlinkbutton.cpp $(CXX) -c -o $@ $(ADVLIB_CXXFLAGS) $(CPPDEPS) $< +$(OBJS)\advlib_hyperlink.o: ../../src/msw/hyperlink.cpp + $(CXX) -c -o $@ $(ADVLIB_CXXFLAGS) $(CPPDEPS) $< + $(OBJS)\advlib_notifmsg.o: ../../src/msw/notifmsg.cpp $(CXX) -c -o $@ $(ADVLIB_CXXFLAGS) $(CPPDEPS) $< diff --git a/build/msw/makefile.vc b/build/msw/makefile.vc index ea143c4a2a..b61d9660c6 100644 --- a/build/msw/makefile.vc +++ b/build/msw/makefile.vc @@ -2399,6 +2399,7 @@ ____ADVANCED_SRC_FILENAMES_OBJECTS = \ $(OBJS)\monodll_taskbarcmn.obj \ $(OBJS)\monodll_aboutdlg.obj \ $(OBJS)\monodll_commandlinkbutton.obj \ + $(OBJS)\monodll_hyperlink.obj \ $(OBJS)\monodll_notifmsg.obj \ $(OBJS)\monodll_sound.obj \ $(OBJS)\monodll_taskbar.obj \ @@ -2440,6 +2441,7 @@ ____ADVANCED_SRC_FILENAMES_OBJECTS = \ $(OBJS)\monodll_taskbarcmn.obj \ $(OBJS)\monodll_aboutdlg.obj \ $(OBJS)\monodll_commandlinkbutton.obj \ + $(OBJS)\monodll_hyperlink.obj \ $(OBJS)\monodll_notifmsg.obj \ $(OBJS)\monodll_sound.obj \ $(OBJS)\monodll_taskbar.obj \ @@ -3118,6 +3120,7 @@ ____ADVANCED_SRC_FILENAMES_1_OBJECTS = \ $(OBJS)\monolib_taskbarcmn.obj \ $(OBJS)\monolib_aboutdlg.obj \ $(OBJS)\monolib_commandlinkbutton.obj \ + $(OBJS)\monolib_hyperlink.obj \ $(OBJS)\monolib_notifmsg.obj \ $(OBJS)\monolib_sound.obj \ $(OBJS)\monolib_taskbar.obj \ @@ -3159,6 +3162,7 @@ ____ADVANCED_SRC_FILENAMES_1_OBJECTS = \ $(OBJS)\monolib_taskbarcmn.obj \ $(OBJS)\monolib_aboutdlg.obj \ $(OBJS)\monolib_commandlinkbutton.obj \ + $(OBJS)\monolib_hyperlink.obj \ $(OBJS)\monolib_notifmsg.obj \ $(OBJS)\monolib_sound.obj \ $(OBJS)\monolib_taskbar.obj \ @@ -4320,6 +4324,7 @@ ____ADVANCED_SRC_FILENAMES_2_OBJECTS = \ $(OBJS)\advdll_taskbarcmn.obj \ $(OBJS)\advdll_aboutdlg.obj \ $(OBJS)\advdll_commandlinkbutton.obj \ + $(OBJS)\advdll_hyperlink.obj \ $(OBJS)\advdll_notifmsg.obj \ $(OBJS)\advdll_sound.obj \ $(OBJS)\advdll_taskbar.obj \ @@ -4361,6 +4366,7 @@ ____ADVANCED_SRC_FILENAMES_2_OBJECTS = \ $(OBJS)\advdll_taskbarcmn.obj \ $(OBJS)\advdll_aboutdlg.obj \ $(OBJS)\advdll_commandlinkbutton.obj \ + $(OBJS)\advdll_hyperlink.obj \ $(OBJS)\advdll_notifmsg.obj \ $(OBJS)\advdll_sound.obj \ $(OBJS)\advdll_taskbar.obj \ @@ -4408,6 +4414,7 @@ ____ADVANCED_SRC_FILENAMES_3_OBJECTS = \ $(OBJS)\advlib_taskbarcmn.obj \ $(OBJS)\advlib_aboutdlg.obj \ $(OBJS)\advlib_commandlinkbutton.obj \ + $(OBJS)\advlib_hyperlink.obj \ $(OBJS)\advlib_notifmsg.obj \ $(OBJS)\advlib_sound.obj \ $(OBJS)\advlib_taskbar.obj \ @@ -4449,6 +4456,7 @@ ____ADVANCED_SRC_FILENAMES_3_OBJECTS = \ $(OBJS)\advlib_taskbarcmn.obj \ $(OBJS)\advlib_aboutdlg.obj \ $(OBJS)\advlib_commandlinkbutton.obj \ + $(OBJS)\advlib_hyperlink.obj \ $(OBJS)\advlib_notifmsg.obj \ $(OBJS)\advlib_sound.obj \ $(OBJS)\advlib_taskbar.obj \ @@ -8471,6 +8479,11 @@ $(OBJS)\monodll_commandlinkbutton.obj: ..\..\src\msw\commandlinkbutton.cpp $(CXX) /c /nologo /TP /Fo$@ $(MONODLL_CXXFLAGS) ..\..\src\msw\commandlinkbutton.cpp !endif +!if "$(USE_GUI)" == "1" +$(OBJS)\monodll_hyperlink.obj: ..\..\src\msw\hyperlink.cpp + $(CXX) /c /nologo /TP /Fo$@ $(MONODLL_CXXFLAGS) ..\..\src\msw\hyperlink.cpp +!endif + !if "$(USE_GUI)" == "1" $(OBJS)\monodll_notifmsg.obj: ..\..\src\msw\notifmsg.cpp $(CXX) /c /nologo /TP /Fo$@ $(MONODLL_CXXFLAGS) ..\..\src\msw\notifmsg.cpp @@ -10688,6 +10701,11 @@ $(OBJS)\monolib_commandlinkbutton.obj: ..\..\src\msw\commandlinkbutton.cpp $(CXX) /c /nologo /TP /Fo$@ $(MONOLIB_CXXFLAGS) ..\..\src\msw\commandlinkbutton.cpp !endif +!if "$(USE_GUI)" == "1" +$(OBJS)\monolib_hyperlink.obj: ..\..\src\msw\hyperlink.cpp + $(CXX) /c /nologo /TP /Fo$@ $(MONOLIB_CXXFLAGS) ..\..\src\msw\hyperlink.cpp +!endif + !if "$(USE_GUI)" == "1" $(OBJS)\monolib_notifmsg.obj: ..\..\src\msw\notifmsg.cpp $(CXX) /c /nologo /TP /Fo$@ $(MONOLIB_CXXFLAGS) ..\..\src\msw\notifmsg.cpp @@ -14165,6 +14183,9 @@ $(OBJS)\advdll_aboutdlg.obj: ..\..\src\msw\aboutdlg.cpp $(OBJS)\advdll_commandlinkbutton.obj: ..\..\src\msw\commandlinkbutton.cpp $(CXX) /c /nologo /TP /Fo$@ $(ADVDLL_CXXFLAGS) ..\..\src\msw\commandlinkbutton.cpp +$(OBJS)\advdll_hyperlink.obj: ..\..\src\msw\hyperlink.cpp + $(CXX) /c /nologo /TP /Fo$@ $(ADVDLL_CXXFLAGS) ..\..\src\msw\hyperlink.cpp + $(OBJS)\advdll_notifmsg.obj: ..\..\src\msw\notifmsg.cpp $(CXX) /c /nologo /TP /Fo$@ $(ADVDLL_CXXFLAGS) ..\..\src\msw\notifmsg.cpp @@ -14282,6 +14303,9 @@ $(OBJS)\advlib_aboutdlg.obj: ..\..\src\msw\aboutdlg.cpp $(OBJS)\advlib_commandlinkbutton.obj: ..\..\src\msw\commandlinkbutton.cpp $(CXX) /c /nologo /TP /Fo$@ $(ADVLIB_CXXFLAGS) ..\..\src\msw\commandlinkbutton.cpp +$(OBJS)\advlib_hyperlink.obj: ..\..\src\msw\hyperlink.cpp + $(CXX) /c /nologo /TP /Fo$@ $(ADVLIB_CXXFLAGS) ..\..\src\msw\hyperlink.cpp + $(OBJS)\advlib_notifmsg.obj: ..\..\src\msw\notifmsg.cpp $(CXX) /c /nologo /TP /Fo$@ $(ADVLIB_CXXFLAGS) ..\..\src\msw\notifmsg.cpp diff --git a/build/msw/makefile.wat b/build/msw/makefile.wat index 131834e02b..b7d3a3ef5d 100644 --- a/build/msw/makefile.wat +++ b/build/msw/makefile.wat @@ -766,6 +766,7 @@ ____ADVANCED_SRC_FILENAMES_OBJECTS = & $(OBJS)\monodll_taskbarcmn.obj & $(OBJS)\monodll_aboutdlg.obj & $(OBJS)\monodll_commandlinkbutton.obj & + $(OBJS)\monodll_hyperlink.obj & $(OBJS)\monodll_notifmsg.obj & $(OBJS)\monodll_sound.obj & $(OBJS)\monodll_taskbar.obj & @@ -807,6 +808,7 @@ ____ADVANCED_SRC_FILENAMES_OBJECTS = & $(OBJS)\monodll_taskbarcmn.obj & $(OBJS)\monodll_aboutdlg.obj & $(OBJS)\monodll_commandlinkbutton.obj & + $(OBJS)\monodll_hyperlink.obj & $(OBJS)\monodll_notifmsg.obj & $(OBJS)\monodll_sound.obj & $(OBJS)\monodll_taskbar.obj & @@ -1490,6 +1492,7 @@ ____ADVANCED_SRC_FILENAMES_1_OBJECTS = & $(OBJS)\monolib_taskbarcmn.obj & $(OBJS)\monolib_aboutdlg.obj & $(OBJS)\monolib_commandlinkbutton.obj & + $(OBJS)\monolib_hyperlink.obj & $(OBJS)\monolib_notifmsg.obj & $(OBJS)\monolib_sound.obj & $(OBJS)\monolib_taskbar.obj & @@ -1531,6 +1534,7 @@ ____ADVANCED_SRC_FILENAMES_1_OBJECTS = & $(OBJS)\monolib_taskbarcmn.obj & $(OBJS)\monolib_aboutdlg.obj & $(OBJS)\monolib_commandlinkbutton.obj & + $(OBJS)\monolib_hyperlink.obj & $(OBJS)\monolib_notifmsg.obj & $(OBJS)\monolib_sound.obj & $(OBJS)\monolib_taskbar.obj & @@ -2646,6 +2650,7 @@ ____ADVANCED_SRC_FILENAMES_2_OBJECTS = & $(OBJS)\advdll_taskbarcmn.obj & $(OBJS)\advdll_aboutdlg.obj & $(OBJS)\advdll_commandlinkbutton.obj & + $(OBJS)\advdll_hyperlink.obj & $(OBJS)\advdll_notifmsg.obj & $(OBJS)\advdll_sound.obj & $(OBJS)\advdll_taskbar.obj & @@ -2687,6 +2692,7 @@ ____ADVANCED_SRC_FILENAMES_2_OBJECTS = & $(OBJS)\advdll_taskbarcmn.obj & $(OBJS)\advdll_aboutdlg.obj & $(OBJS)\advdll_commandlinkbutton.obj & + $(OBJS)\advdll_hyperlink.obj & $(OBJS)\advdll_notifmsg.obj & $(OBJS)\advdll_sound.obj & $(OBJS)\advdll_taskbar.obj & @@ -2734,6 +2740,7 @@ ____ADVANCED_SRC_FILENAMES_3_OBJECTS = & $(OBJS)\advlib_taskbarcmn.obj & $(OBJS)\advlib_aboutdlg.obj & $(OBJS)\advlib_commandlinkbutton.obj & + $(OBJS)\advlib_hyperlink.obj & $(OBJS)\advlib_notifmsg.obj & $(OBJS)\advlib_sound.obj & $(OBJS)\advlib_taskbar.obj & @@ -2775,6 +2782,7 @@ ____ADVANCED_SRC_FILENAMES_3_OBJECTS = & $(OBJS)\advlib_taskbarcmn.obj & $(OBJS)\advlib_aboutdlg.obj & $(OBJS)\advlib_commandlinkbutton.obj & + $(OBJS)\advlib_hyperlink.obj & $(OBJS)\advlib_notifmsg.obj & $(OBJS)\advlib_sound.obj & $(OBJS)\advlib_taskbar.obj & @@ -8300,6 +8308,11 @@ $(OBJS)\monodll_commandlinkbutton.obj : .AUTODEPEND ..\..\src\msw\commandlinkbu $(CXX) -bt=nt -zq -fo=$^@ $(MONODLL_CXXFLAGS) $< !endif +!ifeq USE_GUI 1 +$(OBJS)\monodll_hyperlink.obj : .AUTODEPEND ..\..\src\msw\hyperlink.cpp + $(CXX) -bt=nt -zq -fo=$^@ $(MONODLL_CXXFLAGS) $< +!endif + !ifeq USE_GUI 1 $(OBJS)\monodll_notifmsg.obj : .AUTODEPEND ..\..\src\msw\notifmsg.cpp $(CXX) -bt=nt -zq -fo=$^@ $(MONODLL_CXXFLAGS) $< @@ -10517,6 +10530,11 @@ $(OBJS)\monolib_commandlinkbutton.obj : .AUTODEPEND ..\..\src\msw\commandlinkbu $(CXX) -bt=nt -zq -fo=$^@ $(MONOLIB_CXXFLAGS) $< !endif +!ifeq USE_GUI 1 +$(OBJS)\monolib_hyperlink.obj : .AUTODEPEND ..\..\src\msw\hyperlink.cpp + $(CXX) -bt=nt -zq -fo=$^@ $(MONOLIB_CXXFLAGS) $< +!endif + !ifeq USE_GUI 1 $(OBJS)\monolib_notifmsg.obj : .AUTODEPEND ..\..\src\msw\notifmsg.cpp $(CXX) -bt=nt -zq -fo=$^@ $(MONOLIB_CXXFLAGS) $< @@ -13994,6 +14012,9 @@ $(OBJS)\advdll_aboutdlg.obj : .AUTODEPEND ..\..\src\msw\aboutdlg.cpp $(OBJS)\advdll_commandlinkbutton.obj : .AUTODEPEND ..\..\src\msw\commandlinkbutton.cpp $(CXX) -bt=nt -zq -fo=$^@ $(ADVDLL_CXXFLAGS) $< +$(OBJS)\advdll_hyperlink.obj : .AUTODEPEND ..\..\src\msw\hyperlink.cpp + $(CXX) -bt=nt -zq -fo=$^@ $(ADVDLL_CXXFLAGS) $< + $(OBJS)\advdll_notifmsg.obj : .AUTODEPEND ..\..\src\msw\notifmsg.cpp $(CXX) -bt=nt -zq -fo=$^@ $(ADVDLL_CXXFLAGS) $< @@ -14111,6 +14132,9 @@ $(OBJS)\advlib_aboutdlg.obj : .AUTODEPEND ..\..\src\msw\aboutdlg.cpp $(OBJS)\advlib_commandlinkbutton.obj : .AUTODEPEND ..\..\src\msw\commandlinkbutton.cpp $(CXX) -bt=nt -zq -fo=$^@ $(ADVLIB_CXXFLAGS) $< +$(OBJS)\advlib_hyperlink.obj : .AUTODEPEND ..\..\src\msw\hyperlink.cpp + $(CXX) -bt=nt -zq -fo=$^@ $(ADVLIB_CXXFLAGS) $< + $(OBJS)\advlib_notifmsg.obj : .AUTODEPEND ..\..\src\msw\notifmsg.cpp $(CXX) -bt=nt -zq -fo=$^@ $(ADVLIB_CXXFLAGS) $< diff --git a/build/msw/wx_adv.dsp b/build/msw/wx_adv.dsp index c71409f04c..199de88755 100644 --- a/build/msw/wx_adv.dsp +++ b/build/msw/wx_adv.dsp @@ -426,6 +426,10 @@ SOURCE=..\..\src\msw\datectrl.cpp # End Source File # Begin Source File +SOURCE=..\..\src\msw\hyperlink.cpp +# End Source File +# Begin Source File + SOURCE=..\..\src\msw\joystick.cpp # End Source File # Begin Source File @@ -822,6 +826,10 @@ InputPath=..\..\include\wx\msw\genrcdefs.h # End Source File # Begin Source File +SOURCE=..\..\include\wx\msw\hyperlink.h +# End Source File +# Begin Source File + SOURCE=..\..\include\wx\msw\joystick.h # End Source File # Begin Source File diff --git a/build/msw/wx_core.dsp b/build/msw/wx_core.dsp index d41130effd..53620c05fb 100644 --- a/build/msw/wx_core.dsp +++ b/build/msw/wx_core.dsp @@ -5058,6 +5058,10 @@ SOURCE=..\..\include\wx\msw\htmlhelp.h # End Source File # Begin Source File +SOURCE=..\..\include\wx\msw\hyperlink.h +# End Source File +# Begin Source File + SOURCE=..\..\include\wx\msw\icon.h # End Source File # Begin Source File diff --git a/build/msw/wx_vc7_adv.vcproj b/build/msw/wx_vc7_adv.vcproj index 9617ea40be..b267fb8673 100644 --- a/build/msw/wx_vc7_adv.vcproj +++ b/build/msw/wx_vc7_adv.vcproj @@ -667,6 +667,9 @@ Name="DLL Universal Release|Win32" ExcludedFromBuild="TRUE"/> + + @@ -953,6 +956,9 @@ AdditionalDependencies=""..\..\lib\vc_dll\mswunivu\wx\msw""/> + + diff --git a/build/msw/wx_vc7_core.vcproj b/build/msw/wx_vc7_core.vcproj index 0399e32239..2b829f6e30 100644 --- a/build/msw/wx_vc7_core.vcproj +++ b/build/msw/wx_vc7_core.vcproj @@ -4395,6 +4395,9 @@ + + diff --git a/build/msw/wx_vc8_adv.vcproj b/build/msw/wx_vc8_adv.vcproj index 1771ca1ca8..4a3dc208d5 100644 --- a/build/msw/wx_vc8_adv.vcproj +++ b/build/msw/wx_vc8_adv.vcproj @@ -923,6 +923,10 @@ ExcludedFromBuild="true" /> + + @@ -1290,6 +1294,10 @@ /> + + diff --git a/build/msw/wx_vc8_core.vcproj b/build/msw/wx_vc8_core.vcproj index 27042f1f7c..e0f90ca90b 100644 --- a/build/msw/wx_vc8_core.vcproj +++ b/build/msw/wx_vc8_core.vcproj @@ -5879,6 +5879,10 @@ RelativePath="..\..\include\wx\msw\htmlhelp.h" > + + diff --git a/build/msw/wx_vc9_adv.vcproj b/build/msw/wx_vc9_adv.vcproj index 340e1479d8..4671821eda 100644 --- a/build/msw/wx_vc9_adv.vcproj +++ b/build/msw/wx_vc9_adv.vcproj @@ -919,6 +919,10 @@ ExcludedFromBuild="true" /> + + @@ -1286,6 +1290,10 @@ /> + + diff --git a/build/msw/wx_vc9_core.vcproj b/build/msw/wx_vc9_core.vcproj index 4a79a85eea..1f033cfcf9 100644 --- a/build/msw/wx_vc9_core.vcproj +++ b/build/msw/wx_vc9_core.vcproj @@ -5875,6 +5875,10 @@ RelativePath="..\..\include\wx\msw\htmlhelp.h" > + + diff --git a/docs/changes.txt b/docs/changes.txt index d7dc3c373f..2c59d6a262 100644 --- a/docs/changes.txt +++ b/docs/changes.txt @@ -406,6 +406,7 @@ Major new features in this release MSW: - Fix Cygwin 1.7 build (David Gangola). +- Native wxHyperlinkCtrl implementation (Rickard Westerlund, GSoC 2010 project). - Allow using wxDC::DrawText() with multiline texts. - Fix wxBitmapButton best size determination broken in 2.9.1. diff --git a/include/wx/generic/hyperlink.h b/include/wx/generic/hyperlink.h index f50ded8859..9146ba8ada 100644 --- a/include/wx/generic/hyperlink.h +++ b/include/wx/generic/hyperlink.h @@ -20,7 +20,7 @@ class WXDLLIMPEXP_ADV wxGenericHyperlinkCtrl : public wxHyperlinkCtrlBase { public: // Default constructor (for two-step construction). - wxGenericHyperlinkCtrl() { } + wxGenericHyperlinkCtrl() { Init(); } // Constructor. wxGenericHyperlinkCtrl(wxWindow *parent, @@ -31,7 +31,8 @@ public: long style = wxHL_DEFAULT_STYLE, const wxString& name = wxHyperlinkCtrlNameStr) { - (void)Create(parent, id, label, url, pos, size, style, name); + Init(); + (void) Create(parent, id, label, url, pos, size, style, name); } // Creation function (for two-step construction). @@ -65,6 +66,10 @@ public: protected: + // Helper used by this class itself and native MSW implementation that + // connects OnRightUp() and OnPopUpCopy() handlers. + void ConnectMenuHandlers(); + // event handlers // Renders the hyperlink. @@ -100,12 +105,15 @@ protected: // Returns the best size for the window, which is the size needed // to display the text label. - virtual wxSize DoGetBestSize() const; + virtual wxSize DoGetBestClientSize() const; // creates a context menu with "Copy URL" menuitem virtual void DoContextMenu(const wxPoint &); private: + // Common part of all ctors. + void Init(); + // URL associated with the link. This is transmitted inside // the HyperlinkEvent fired when the user clicks on the label. wxString m_url; @@ -126,9 +134,6 @@ private: // True if a click is in progress (left button down) and the click // originated inside the label's bounding box. bool m_clicking; - -private: - DECLARE_DYNAMIC_CLASS(wxGenericHyperlinkCtrl) }; #endif // _WX_GENERICHYPERLINKCTRL_H_ diff --git a/include/wx/hyperlink.h b/include/wx/hyperlink.h index 2678203ff9..8478ede57b 100644 --- a/include/wx/hyperlink.h +++ b/include/wx/hyperlink.h @@ -135,9 +135,32 @@ typedef void (wxEvtHandler::*wxHyperlinkEventFunction)(wxHyperlinkEvent&); #if defined(__WXGTK210__) && !defined(__WXUNIVERSAL__) #include "wx/gtk/hyperlink.h" +#elif defined(__WXMSW__) && !defined(__WXUNIVERSAL__) + #include "wx/msw/hyperlink.h" #else #include "wx/generic/hyperlink.h" - #define wxHyperlinkCtrl wxGenericHyperlinkCtrl + + class WXDLLIMPEXP_ADV wxHyperlinkCtrl : public wxGenericHyperlinkCtrl + { + public: + wxHyperlinkCtrl() { } + + wxHyperlinkCtrl(wxWindow *parent, + wxWindowID id, + const wxString& label, + const wxString& url, + const wxPoint& pos = wxDefaultPosition, + const wxSize& size = wxDefaultSize, + long style = wxHL_DEFAULT_STYLE, + const wxString& name = wxHyperlinkCtrlNameStr) + : wxGenericHyperlinkCtrl(parent, id, label, url, pos, size, + style, name) + { + } + + private: + wxDECLARE_DYNAMIC_CLASS_NO_COPY( wxHyperlinkCtrl ); + }; #endif diff --git a/include/wx/msw/hyperlink.h b/include/wx/msw/hyperlink.h new file mode 100644 index 0000000000..43c16c5ee5 --- /dev/null +++ b/include/wx/msw/hyperlink.h @@ -0,0 +1,65 @@ +///////////////////////////////////////////////////////////////////////////// +// Name: wx/msw/hyperlink.h +// Purpose: Hyperlink control +// Author: Rickard Westerlund +// Created: 2010-08-04 +// RCS-ID: $Id$ +// Copyright: (c) 2010 wxWidgets team +// Licence: wxWindows licence +///////////////////////////////////////////////////////////////////////////// + +#ifndef _WX_MSW_HYPERLINK_H_ +#define _WX_MSW_HYPERLINK_H_ + +#include "wx/generic/hyperlink.h" + +// ---------------------------------------------------------------------------- +// wxHyperlinkCtrl +// ---------------------------------------------------------------------------- + +class WXDLLIMPEXP_ADV wxHyperlinkCtrl : public wxGenericHyperlinkCtrl +{ +public: + // Default constructor (for two-step construction). + wxHyperlinkCtrl() { } + + // Constructor. + wxHyperlinkCtrl(wxWindow *parent, + wxWindowID id, + const wxString& label, const wxString& url, + const wxPoint& pos = wxDefaultPosition, + const wxSize& size = wxDefaultSize, + long style = wxHL_DEFAULT_STYLE, + const wxString& name = wxHyperlinkCtrlNameStr) + { + (void)Create(parent, id, label, url, pos, size, style, name); + } + + // Creation function (for two-step construction). + bool Create(wxWindow *parent, + wxWindowID id, + const wxString& label, const wxString& url, + const wxPoint& pos = wxDefaultPosition, + const wxSize& size = wxDefaultSize, + long style = wxHL_DEFAULT_STYLE, + const wxString& name = wxHyperlinkCtrlNameStr); + + + // overridden base class methods + // ----------------------------- + + virtual void SetURL(const wxString &url); + + virtual void SetLabel(const wxString &label); + +protected: + virtual WXDWORD MSWGetStyle(long style, WXDWORD *exstyle) const; + virtual wxSize DoGetBestClientSize() const; + +private: + virtual bool MSWOnNotify(int idCtrl, WXLPARAM lParam, WXLPARAM *result); + + wxDECLARE_DYNAMIC_CLASS( wxHyperlinkCtrl ); +}; + +#endif // _WX_MSW_HYPERLINK_H_ diff --git a/interface/wx/hyperlink.h b/interface/wx/hyperlink.h index 15dd2519db..1d2bb02c8a 100644 --- a/interface/wx/hyperlink.h +++ b/interface/wx/hyperlink.h @@ -44,6 +44,7 @@ public: @class wxHyperlinkCtrl This class shows a static text element which links to an URL. + Appearance and behaviour is completely customizable. In fact, when the user clicks on the hyperlink, a wxHyperlinkEvent is @@ -58,9 +59,11 @@ public: @style{wxHL_ALIGN_LEFT} Align the text to the left. @style{wxHL_ALIGN_RIGHT} - Align the text to the right. + Align the text to the right. This style is not supported under + Windows XP but is supported under all the other Windows versions. @style{wxHL_ALIGN_CENTRE} - Center the text (horizontally). + Center the text (horizontally). This style is not supported by the + native MSW implementation used under Windows XP and later. @style{wxHL_CONTEXTMENU} Pop up a context menu when the hyperlink is right-clicked. The context menu contains a "Copy URL" menu item which is automatically @@ -78,6 +81,9 @@ public: is done with the hyperlink's URL. @endEventTable + Currently this class is implemented using native support in wxGTK and wxMSW + (under Windows XP and later only) and a generic version is used by the + other ports. @library{wxadv} @category{ctrl} diff --git a/src/common/hyperlnkcmn.cpp b/src/common/hyperlnkcmn.cpp index 7765e21d8b..32bf30c51c 100644 --- a/src/common/hyperlnkcmn.cpp +++ b/src/common/hyperlnkcmn.cpp @@ -42,6 +42,12 @@ // implementation // ============================================================================ +#if wxUSE_EXTENDED_RTTI + wxIMPLEMENT_DYNAMIC_CLASS_XTI( wxHyperlinkCtrl, wxControl, "wx/hyperlink.h") +#else + wxIMPLEMENT_DYNAMIC_CLASS( wxHyperlinkCtrl, wxControl ) +#endif // wxUSE_EXTENDED_RTTI + IMPLEMENT_DYNAMIC_CLASS(wxHyperlinkEvent, wxCommandEvent) wxDEFINE_EVENT( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEvent ); diff --git a/src/generic/hyperlinkg.cpp b/src/generic/hyperlinkg.cpp index 791b15b357..fb8bc57ba1 100644 --- a/src/generic/hyperlinkg.cpp +++ b/src/generic/hyperlinkg.cpp @@ -46,8 +46,6 @@ // implementation // ============================================================================ -IMPLEMENT_DYNAMIC_CLASS(wxGenericHyperlinkCtrl, wxControl) - // reserved for internal use only #define wxHYPERLINK_POPUP_COPY_ID 16384 @@ -72,14 +70,7 @@ bool wxGenericHyperlinkCtrl::Create(wxWindow *parent, wxWindowID id, SetURL(url.empty() ? label : url); SetLabel(label.empty() ? url : label); - m_rollover = false; - m_clicking = false; - m_visited = false; - - // colours - m_normalColour = *wxBLUE; - m_hoverColour = *wxRED; - m_visitedColour = wxColour("#551a8b"); + Init(); SetForegroundColour(m_normalColour); // by default the font of an hyperlink control is underlined @@ -102,26 +93,37 @@ bool wxGenericHyperlinkCtrl::Create(wxWindow *parent, wxWindowID id, Connect( wxEVT_LEFT_DOWN, wxMouseEventHandler(wxGenericHyperlinkCtrl::OnLeftDown) ); Connect( wxEVT_LEFT_UP, wxMouseEventHandler(wxGenericHyperlinkCtrl::OnLeftUp) ); - Connect( wxEVT_RIGHT_UP, wxMouseEventHandler(wxGenericHyperlinkCtrl::OnRightUp) ); Connect( wxEVT_MOTION, wxMouseEventHandler(wxGenericHyperlinkCtrl::OnMotion) ); - Connect( wxHYPERLINK_POPUP_COPY_ID, wxEVT_COMMAND_MENU_SELECTED, - wxCommandEventHandler(wxGenericHyperlinkCtrl::OnPopUpCopy) ); + ConnectMenuHandlers(); return true; } -wxSize wxGenericHyperlinkCtrl::DoGetBestSize() const +void wxGenericHyperlinkCtrl::Init() +{ + m_rollover = false; + m_clicking = false; + m_visited = false; + + // colours + m_normalColour = *wxBLUE; + m_hoverColour = *wxRED; + m_visitedColour = wxColour("#551a8b"); +} + +void wxGenericHyperlinkCtrl::ConnectMenuHandlers() { - int w, h; + // Connect the event handlers for the context menu. + Connect( wxEVT_RIGHT_UP, wxMouseEventHandler(wxGenericHyperlinkCtrl::OnRightUp) ); + Connect( wxHYPERLINK_POPUP_COPY_ID, wxEVT_COMMAND_MENU_SELECTED, + wxCommandEventHandler(wxGenericHyperlinkCtrl::OnPopUpCopy) ); +} +wxSize wxGenericHyperlinkCtrl::DoGetBestClientSize() const +{ wxClientDC dc((wxWindow *)this); - dc.SetFont(GetFont()); - dc.GetTextExtent(GetLabel(), &w, &h); - - wxSize best(w, h); - CacheBestSize(best); - return best; + return dc.GetTextExtent(GetLabel()); } diff --git a/src/gtk/hyperlink.cpp b/src/gtk/hyperlink.cpp index 54b8aa7d8e..84d6f0dd6d 100644 --- a/src/gtk/hyperlink.cpp +++ b/src/gtk/hyperlink.cpp @@ -47,9 +47,6 @@ static inline bool UseNative() // implementation // ============================================================================ -IMPLEMENT_DYNAMIC_CLASS(wxHyperlinkCtrl, wxGenericHyperlinkCtrl) - - // ---------------------------------------------------------------------------- // "clicked" // ---------------------------------------------------------------------------- diff --git a/src/msw/hyperlink.cpp b/src/msw/hyperlink.cpp new file mode 100644 index 0000000000..4e1ec86e7e --- /dev/null +++ b/src/msw/hyperlink.cpp @@ -0,0 +1,172 @@ +///////////////////////////////////////////////////////////////////////////// +// Name: src/msw/hyperlink.cpp +// Purpose: Hyperlink control +// Author: Rickard Westerlund +// Created: 2010-08-03 +// RCS-ID: $Id$ +// Copyright: (c) 2010 wxWidgets team +// Licence: wxWindows licence +///////////////////////////////////////////////////////////////////////////// + +// ---------------------------------------------------------------------------- +// headers +// ---------------------------------------------------------------------------- + +// For compilers that support precompilation, includes "wx.h". +#include "wx/wxprec.h" + +#ifdef __BORLANDC__ + #pragma hdrstop +#endif + +#if wxUSE_HYPERLINKCTRL + +#include "wx/hyperlink.h" + +#ifndef WX_PRECOMP + #include "wx/stattext.h" +#endif + +// ---------------------------------------------------------------------------- +// Definitions +// ---------------------------------------------------------------------------- + +#ifndef LM_GETIDEALSIZE + #define LM_GETIDEALSIZE (WM_USER + 0x301) +#endif + +#ifndef LWS_RIGHT + #define LWS_RIGHT 0x0020 +#endif + +// ---------------------------------------------------------------------------- +// Helper functions +// ---------------------------------------------------------------------------- + +namespace +{ + bool HasNativeHyperlinkCtrl() + { + return wxGetWinVersion() >= wxWinVersion_XP; + } + + wxString GetLabelForSysLink(const wxString& text, const wxString& url) + { + return wxString("" + + wxStaticText::RemoveMarkup(text) + ""; + } +} + +// ---------------------------------------------------------------------------- +// wxHyperlinkCtrl +// ---------------------------------------------------------------------------- + +bool wxHyperlinkCtrl::Create(wxWindow *parent, + wxWindowID id, + const wxString& label, const wxString& url, + const wxPoint& pos, + const wxSize& size, + long style, + const wxString& name) +{ + if ( !HasNativeHyperlinkCtrl() ) + { + return wxGenericHyperlinkCtrl::Create( parent, id, label, url, pos, + size, style, name ); + } + + if ( !CreateControl(parent, id, pos, size, style, + wxDefaultValidator, name) ) + { + return false; + } + + SetURL( url ); + SetVisited( false ); + + WXDWORD exstyle; + WXDWORD msStyle = MSWGetStyle(style, &exstyle); + + if ( !MSWCreateControl(WC_LINK, msStyle, pos, size, + GetLabelForSysLink( label, url ), exstyle) ) + { + return false; + } + + // Make sure both the label and URL are non-empty strings. + SetURL(url.empty() ? label : url); + SetLabel(label.empty() ? url : label); + + ConnectMenuHandlers(); + + return true; +} + +WXDWORD wxHyperlinkCtrl::MSWGetStyle(long style, WXDWORD *exstyle) const +{ + WXDWORD msStyle = wxControl::MSWGetStyle( style, exstyle ); + + if ( style & wxHL_ALIGN_RIGHT ) + msStyle |= LWS_RIGHT; + + return msStyle; +} + +void wxHyperlinkCtrl::SetURL(const wxString &url) +{ + if ( !HasNativeHyperlinkCtrl() ) + { + wxGenericHyperlinkCtrl::SetURL( url ); + return; + } + + if ( GetURL() != url ) + SetVisited( false ); + wxGenericHyperlinkCtrl::SetURL( url ); + wxWindow::SetLabel( GetLabelForSysLink(m_labelOrig, url) ); +} + +void wxHyperlinkCtrl::SetLabel(const wxString &label) +{ + if ( !HasNativeHyperlinkCtrl() ) + { + wxGenericHyperlinkCtrl::SetLabel( label ); + return; + } + + m_labelOrig = label; + wxWindow::SetLabel( GetLabelForSysLink(label, GetURL()) ); + InvalidateBestSize(); +} + +wxSize wxHyperlinkCtrl::DoGetBestClientSize() const +{ + // LM_GETIDEALSIZE only exists under Vista so use the generic version even + // when using the native control under XP + if ( wxGetWinVersion() < wxWinVersion_6 ) + return wxGenericHyperlinkCtrl::DoGetBestClientSize(); + + SIZE idealSize; + ::SendMessage(m_hWnd, LM_GETIDEALSIZE, 0, (LPARAM)&idealSize); + + return wxSize(idealSize.cx, idealSize.cy); +} + +bool wxHyperlinkCtrl::MSWOnNotify(int idCtrl, WXLPARAM lParam, WXLPARAM *result) +{ + if ( HasNativeHyperlinkCtrl() ) + { + switch ( ((LPNMHDR) lParam)->code ) + { + case NM_CLICK: + case NM_RETURN: + SetVisited(); + SendEvent(); + return 0; + } + } + + return wxGenericHyperlinkCtrl::MSWOnNotify(idCtrl, lParam, result); +} + +#endif // wxUSE_HYPERLINKCTRL -- 2.45.2