]> Pileus Git - ~andy/gtk/commitdiff
updated explicit usage of RegisterClassExW to match the WNDCLASSEXW. True
authorHans Breuer <hans@breuer.org>
Fri, 15 Jun 2007 15:25:50 +0000 (15:25 +0000)
committerHans Breuer <hans@src.gnome.org>
Fri, 15 Jun 2007 15:25:50 +0000 (15:25 +0000)
2007-06-15  Hans Breuer <hans@breuer.org>

* gtk/makefile.msc.in tests/makefile.msc : updated
* gdk/win32/gdkwindow-win32.c : explicit usage of RegisterClassExW
to match the WNDCLASSEXW.
True dynamic linking of SetLayeredWindowAttributes
* tests/testprint.c tests/testnouiprint.c : use G_PI

svn path=/trunk/; revision=18140

ChangeLog
gdk/win32/gdkwindow-win32.c
gtk/makefile.msc.in
tests/makefile.msc
tests/testnouiprint.c
tests/testprint.c

index d3227ca064e012c8b79e91177008181eac149270..8e9869c70995041886ef2e604dd58c4594c06100 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2007-06-15  Hans Breuer <hans@breuer.org>
+
+       * gtk/makefile.msc.in tests/makefile.msc : updated
+       * gdk/win32/gdkwindow-win32.c : explicit usage of RegisterClassExW
+       to match the WNDCLASSEXW. 
+       True dynamic linking of SetLayeredWindowAttributes
+       * tests/testprint.c tests/testnouiprint.c : use G_PI
+
 2007-06-14  Johan Dahlin  <jdahlin@async.com.br>
 
        * gtk/gtk.symbols: Add missing symbol 
index ae0b7314d8657d6fd8f4ecd1e8e3ee4abb324f1f..b3baab5afe46bbce2cc9dd3b75d303d49bcdadf9 100644 (file)
@@ -420,7 +420,7 @@ RegisterGdkClass (GdkWindowType wtype, GdkWindowTypeHint wtype_hint)
         {
           if (klassTEMPSHADOW == 0)
             {
-              wcl.lpszClassName = "gdkWindowTempShadow";
+              wcl.lpszClassName = L"gdkWindowTempShadow";
               wcl.style |= CS_SAVEBITS;
               if (LOBYTE (g_win32_get_windows_version()) > 0x05 ||
                  LOWORD (g_win32_get_windows_version()) == 0x0105)
@@ -429,7 +429,7 @@ RegisterGdkClass (GdkWindowType wtype, GdkWindowTypeHint wtype_hint)
                  wcl.style |= 0x00020000; /* CS_DROPSHADOW */
                }
               ONCE_PER_CLASS ();
-              klassTEMPSHADOW = RegisterClassEx (&wcl);
+              klassTEMPSHADOW = RegisterClassExW (&wcl);
             }
 
           klass = klassTEMPSHADOW;
@@ -438,10 +438,10 @@ RegisterGdkClass (GdkWindowType wtype, GdkWindowTypeHint wtype_hint)
         {
           if (klassTEMP == 0)
             {
-              wcl.lpszClassName = "gdkWindowTemp";
+              wcl.lpszClassName = L"gdkWindowTemp";
               wcl.style |= CS_SAVEBITS;
               ONCE_PER_CLASS ();
-              klassTEMP = RegisterClassEx (&wcl);
+              klassTEMP = RegisterClassExW (&wcl);
             }
 
           klass = klassTEMP;
@@ -3551,6 +3551,8 @@ gdk_window_set_opacity (GdkWindow *window,
                        gdouble    opacity)
 {
   LONG exstyle;
+  typedef BOOL (*PFN_SetLayeredWindowAttributes) (HWND, COLORREF, BYTE, DWORD);
+  PFN_SetLayeredWindowAttributes setLayeredWindowAttributes = NULL;
 
   g_return_if_fail (GDK_IS_WINDOW (window));
   g_return_if_fail (WINDOW_IS_TOPLEVEL (window));
@@ -3570,10 +3572,16 @@ gdk_window_set_opacity (GdkWindow *window,
                              GWL_EXSTYLE,
                              exstyle | WS_EX_LAYERED));
 
-  API_CALL (SetLayeredWindowAttributes, (GDK_WINDOW_HWND (window),
-                                        0,
-                                        opacity * 0xff,
-                                        LWA_ALPHA));
+  setLayeredWindowAttributes = 
+    (PFN_SetLayeredWindowAttributes)GetProcAddress (GetModuleHandle ("user32.dll"), "SetLayeredWindowAttributes");
+
+  if (setLayeredWindowAttributes)
+    {
+      API_CALL (setLayeredWindowAttributes, (GDK_WINDOW_HWND (window),
+                                            0,
+                                            opacity * 0xff,
+                                            LWA_ALPHA));
+    }
 }
 
 void
index 6121ce4a7d4d0169f19ad8f6c35b08b3288fd79b..412e2c0a8808682e61c54dc554bf5ed27644c543 100644 (file)
@@ -39,7 +39,8 @@ DEFINES = \
        -DGTK_HOST=\"win32\" \
        -DGTK_FILE_SYSTEM_ENABLE_UNSUPPORTED \
        -DGTK_PRINT_BACKENDS=\"file,lpr\"       \
-       -DGTK_PRINT_PREVIEW_COMMAND="\"evince --unlink-tempfile --preview %f\""
+       -DGTK_PRINT_PREVIEW_COMMAND="\"evince --unlink-tempfile --preview %f\"" \
+       -DGTK_LIBDIR=\"/magic/path/replaced/at/runtime\"
 
 TOUCH = copy makefile.msc+nul
 
@@ -161,6 +162,7 @@ gtk_OBJECTS =                                       \
        gtkhseparator.obj                       \
        gtkhsv.obj                              \
        gtkiconcache.obj                        \
+       gtkiconcachevalidator.obj       \
        gtkiconfactory.obj                      \
        gtkicontheme.obj                        \
        gtkiconview.obj                 \
@@ -214,6 +216,7 @@ gtk_OBJECTS =                                       \
        gtkprintutils.obj       \
        gtkprogress.obj                         \
        gtkprogressbar.obj                      \
+       gtkquery.obj    \
        gtkradioaction.obj                      \
        gtkradiobutton.obj                      \
        gtkradiotoolbutton.obj                  \
@@ -221,6 +224,7 @@ gtk_OBJECTS =                                       \
        gtkrange.obj                            \
        gtkrbtree.obj   \
        gtkrc.obj                               \
+       gtkrecentaction.obj \
        gtkrecentchooserdefault.obj \
        gtkrecentchooserdialog.obj \
        gtkrecentchoosermenu.obj        \
@@ -231,13 +235,17 @@ gtk_OBJECTS =                                     \
        gtkrecentmanager.obj    \
        gtkruler.obj                            \
        gtkscale.obj                            \
+       gtkscalebutton.obj      \
        gtkscrollbar.obj                        \
        gtkscrolledwindow.obj                   \
+       gtksearchengine.obj     \
+       gtksearchenginebeagle.obj       \
+       gtksearchenginesimple.obj       \
+       gtksearchenginetracker.obj      \
        gtkselection.obj                        \
        gtkseparator.obj                        \
        gtkseparatormenuitem.obj \
        gtkseparatortoolitem.obj \
-       gtksequence.obj \
        gtksettings.obj \
        gtksignal.obj                           \
        gtksizegroup.obj \
@@ -274,6 +282,7 @@ gtk_OBJECTS =                                       \
        gtktoolbar.obj                          \
        gtktoolbutton.obj                               \
        gtktoolitem.obj                         \
+       gtktooltip.obj                          \
        gtktooltips.obj                         \
        gtktrayicon-win32.obj   \
        gtktree.obj                             \
@@ -294,6 +303,7 @@ gtk_OBJECTS =                                       \
        gtkvbbox.obj                            \
        gtkvbox.obj                             \
        gtkviewport.obj                         \
+       gtkvolumebutton.obj     \
        gtkvpaned.obj                           \
        gtkvruler.obj                           \
        gtkvscale.obj                           \
@@ -424,12 +434,14 @@ gtk_public_h_sources =            \
        gtkprivate.h            \
        gtkprogress.h           \
        gtkprogressbar.h        \
+       gtkquery.h      \
        gtkradioaction.h        \
        gtkradiobutton.h        \
        gtkradiomenuitem.h      \
        gtkradiotoolbutton.h    \
        gtkrange.h              \
        gtkrc.h                 \
+       gtkrecentaction.h       \
        gtkrecentchooser.h      \
        gtkrecentchooserdialog.h \
        gtkrecentchoosermenu.h  \
@@ -438,8 +450,10 @@ gtk_public_h_sources =             \
        gtkrecentmanager.h      \
        gtkruler.h              \
        gtkscale.h              \
+       gtkscalebutton.h        \
        gtkscrollbar.h          \
        gtkscrolledwindow.h     \
+       gtksearchengine.h       \
        gtkselection.h          \
        gtkseparator.h          \
        gtkseparatormenuitem.h  \
@@ -490,6 +504,7 @@ gtk_public_h_sources =              \
        gtkvbbox.h              \
        gtkvbox.h               \
        gtkviewport.h           \
+       gtkvolumebutton.h       \
        gtkvpaned.h             \
        gtkvruler.h             \
        gtkvscale.h             \
index f849a82c43fbd3dbdb2cf2828c7b07fa02ca0d96..2db726f867d163442a105a02e99f9ebc110f2c2b 100644 (file)
@@ -41,22 +41,24 @@ all :       \
 #
 TESTAPPS = \
        autotestfilechooser floatingtest \
-       testaccel testactions \
+       testaccel testactions testassistant \
+       testbbox \
        testcairo testcalendar testcellrenderertext testcombo testcombochange \
        testdnd \
        testellipsise testentrycompletion \
        testfilechooser testfilechooserbutton \
-       testgtk \
+       testgrouping testgtk \
        testicontheme testiconview testimage testinput \
        testmenus testmenubars testmerge testmultidisplay testmultiscreen \
-       testnotebookdnd \
-       testrecentchooser testrgb \
+       testnouiprint testnotebookdnd \
+       testprint \
+       testrecentchooser testrecentchoosermenu testrgb testrichtext \
        testselection testspinbutton \
-       testtext testtextbuffer testtoolbar \
+       testtext testtextbuffer testtoolbar testtooltips \
        testtreecolumns testtreeedit testtreeflow testtreefocus \
-       testtreesort testtreeview treestoretest \
+       testtreemodel testtreesort testtreeview treestoretest \
        testsocket testsocket_child teststatusicon \
-       testthreads testxinerama \
+       testthreads testvolumebutton testxinerama \
        simple 
 
 # syntax error : illegal character '-' in macro
@@ -71,25 +73,20 @@ one-test-app:
 
 !ELSE
 
-!IFDEF EXTRA_testcairo
-EXTRA_LIBS = $(CAIRO_LIBS)
-!ENDIF
-
-!IFDEF EXTRA_testentrycompletion
 EXTRA_OBJETCS = prop-editor.obj
-!ENDIF
 
-!IFDEF EXTRA_testfilechooserbutton
-EXTRA_OBJETCS = prop-editor.obj
+
+!IFDEF EXTRA_testprint
+EXTRA_OBJETCS = testprintfileoperation.obj
+EXTRA_LIBS = $(PANGOCAIRO_LIBS)
 !ENDIF
 
-!IFDEF EXTRA_testgtk
-EXTRA_LIBS = $(CAIRO_LIBS)
-EXTRA_OBJETCS = prop-editor.obj
+!IFDEF EXTRA_testnouiprint
+EXTRA_LIBS = $(PANGOCAIRO_LIBS)
 !ENDIF
 
-!IFDEF EXTRA_testiconview
-EXTRA_OBJETCS = prop-editor.obj
+!IFDEF EXTRA_testfilechooser
+EXTRA_LIBS = gdi32.lib user32.lib shell32.lib
 !ENDIF
 
 !IFDEF EXTRA_testsocket
@@ -100,29 +97,9 @@ EXTRA_OBJETCS = testsocket_common.obj
 EXTRA_OBJETCS = testsocket_common.obj
 !ENDIF
 
-!IFDEF EXTRA_testrecentchooser
-EXTRA_OBJETCS = prop-editor.obj
-!ENDIF
-
-!IFDEF EXTRA_testtreeview
-EXTRA_OBJETCS = prop-editor.obj
-!ENDIF
-
-!IFDEF EXTRA_testtext
-EXTRA_OBJETCS = prop-editor.obj
-!ENDIF
-
-!IFDEF EXTRA_testtoolbar
-EXTRA_OBJETCS = prop-editor.obj
-!ENDIF
-
-!IFDEF EXTRA_testfilechooser
-EXTRA_OBJETCS = prop-editor.obj
-EXTRA_LIBS = gdi32.lib user32.lib shell32.lib
-!ENDIF
-
-$(TESTAPP).exe : ../gtk/gtk-win32-$(GTK_VER).lib $(TESTAPP).obj
-       $(CC) $(CFLAGS) $(TESTAPP).obj $(EXTRA_OBJETCS) $(GTK_LIBS) $(GDK_LIBS) $(GDK_PIXBUF_LIBS) $(PANGO_LIBS) $(GLIB_LIBS) $(EXTRA_LIBS) $(LDFLAGS)
+$(TESTAPP).exe : ../gtk/gtk-win32-$(GTK_VER).lib $(TESTAPP).obj $(EXTRA_OBJETCS)
+       $(CC) $(CFLAGS) $(TESTAPP).obj $(EXTRA_OBJETCS) $(GTK_LIBS) $(GDK_LIBS) $(GDK_PIXBUF_LIBS) \
+       $(PANGO_LIBS) $(GLIB_LIBS) $(CAIRO_LIBS) $(EXTRA_LIBS) $(LDFLAGS)
 
 $(TESTAPP).obj : $(TESTAPP).c
        $(CC) $(CFLAGS) -c -DG_LOG_DOMAIN=\"$(TESTAPP)\" $(TESTAPP).c
index 1c39ae9a7cacb6d49137fcfb82fc400167fc6a34..09a678f375687ec3e66ef9d4e27febe7569d2bf9 100644 (file)
@@ -42,7 +42,7 @@ draw_page (GtkPrintOperation *operation,
   /* Draw some lines */
   cairo_move_to (cr, 20, 10);
   cairo_line_to (cr, 40, 20);
-  cairo_arc (cr, 60, 60, 20, 0, M_PI);
+  cairo_arc (cr, 60, 60, 20, 0, G_PI);
   cairo_line_to (cr, 80, 20);
   
   cairo_set_source_rgb (cr, 0, 0, 0);
index e39c3a9914b22350f5cac85cac8a2cdf808eb83d..1da7af97d93e7560ef2a9a1be0ea1d5895100753 100644 (file)
@@ -62,7 +62,7 @@ draw_page (GtkPrintOperation *operation,
   /* Draw some lines */
   cairo_move_to (cr, 20, 10);
   cairo_line_to (cr, 40, 20);
-  cairo_arc (cr, 60, 60, 20, 0, M_PI);
+  cairo_arc (cr, 60, 60, 20, 0, G_PI);
   cairo_line_to (cr, 80, 20);
   
   cairo_set_source_rgb (cr, 0, 0, 0);