Changeset 206513 in webkit


Ignore:
Timestamp:
Sep 28, 2016 5:54:50 AM (8 years ago)
Author:
Michael Catanzaro
Message:

[GTK] Simplify platformForUAString
https://bugs.webkit.org/show_bug.cgi?id=162614

Reviewed by Carlos Garcia Campos.

Note in particular that the previous PLATFORM(MAC) check was wrong here, as that is never
true for GTK; this patch risks changing it to OS(MAC_OS_X), on the hope that advertising Mac
when running on Mac might not break anything. If it does, then we should remove it and just
always pretend to be on X11.

  • platform/gtk/UserAgentGtk.cpp:

(WebCore::platformForUAString):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r206512 r206513  
     12016-09-28  Michael Catanzaro  <mcatanzaro@igalia.com>
     2
     3        [GTK] Simplify platformForUAString
     4        https://bugs.webkit.org/show_bug.cgi?id=162614
     5
     6        Reviewed by Carlos Garcia Campos.
     7
     8        Note in particular that the previous PLATFORM(MAC) check was wrong here, as that is never
     9        true for GTK; this patch risks changing it to OS(MAC_OS_X), on the hope that advertising Mac
     10        when running on Mac might not break anything. If it does, then we should remove it and just
     11        always pretend to be on X11.
     12
     13        * platform/gtk/UserAgentGtk.cpp:
     14        (WebCore::platformForUAString):
     15
    1162016-09-28  Michael Catanzaro  <mcatanzaro@igalia.com>
    217
  • trunk/Source/WebCore/platform/gtk/UserAgentGtk.cpp

    r206512 r206513  
    9191static const char* platformForUAString()
    9292{
    93 #if PLATFORM(X11)
     93#if OS(MAC_OS_X)
     94    return "Macintosh";
     95#else
    9496    return "X11";
    95 #elif OS(WINDOWS)
    96     return "";
    97 #elif PLATFORM(MAC)
    98     return "Macintosh";
    99 #elif defined(GDK_WINDOWING_DIRECTFB)
    100     return "DirectFB";
    101 #else
    102     return "Unknown";
    10397#endif
    10498}
Note: See TracChangeset for help on using the changeset viewer.