Fix compilation of LocaleWin with !ENABLE(CALENDAR_PICKER) && !ENABLE(DATE_AND_TIME_I...
authorparoga@webkit.org <paroga@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 7 Apr 2013 18:30:17 +0000 (18:30 +0000)
committerparoga@webkit.org <paroga@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 7 Apr 2013 18:30:17 +0000 (18:30 +0000)
* platform/text/win/LocaleWin.cpp:
(WebCore::LocaleWin::ensureShortMonthLabels):
(WebCore):
(WebCore::LocaleWin::ensureMonthLabels):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@147869 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/platform/text/win/LocaleWin.cpp

index ffaf322..25a82b7 100644 (file)
@@ -1,5 +1,14 @@
 2013-04-07  Patrick Gansterer  <paroga@webkit.org>
 
+        Fix compilation of LocaleWin with !ENABLE(CALENDAR_PICKER) && !ENABLE(DATE_AND_TIME_INPUT_TYPES)
+
+        * platform/text/win/LocaleWin.cpp:
+        (WebCore::LocaleWin::ensureShortMonthLabels):
+        (WebCore):
+        (WebCore::LocaleWin::ensureMonthLabels):
+
+2013-04-07  Patrick Gansterer  <paroga@webkit.org>
+
         [WIN] Fix build without precompiled header after r144216.
 
         * platform/network/cf/FormDataStreamCFNet.h:
index 1faee26..ede270c 100644 (file)
@@ -192,6 +192,7 @@ void LocaleWin::getLocaleInfo(LCTYPE type, DWORD& result)
 
 void LocaleWin::ensureShortMonthLabels()
 {
+#if ENABLE(DATE_AND_TIME_INPUT_TYPES)
     if (!m_shortMonthLabels.isEmpty())
         return;
     const LCTYPE types[12] = {
@@ -219,10 +220,12 @@ void LocaleWin::ensureShortMonthLabels()
             return;
         }
     }
+#endif
 }
 
 // -------------------------------- Tokenized date format
 
+#if ENABLE(DATE_AND_TIME_INPUT_TYPES)
 static unsigned countContinuousLetters(const String& format, unsigned index)
 {
     unsigned count = 1;
@@ -320,9 +323,11 @@ static String convertWindowsDateTimeFormat(const String& format)
     commitLiteralToken(literalBuffer, converted);
     return converted.toString();
 }
+#endif
 
 void LocaleWin::ensureMonthLabels()
 {
+#if ENABLE(DATE_AND_TIME_INPUT_TYPES)
     if (!m_monthLabels.isEmpty())
         return;
     const LCTYPE types[12] = {
@@ -350,8 +355,10 @@ void LocaleWin::ensureMonthLabels()
             return;
         }
     }
+#endif
 }
 
+#if ENABLE(CALENDAR_PICKER)
 void LocaleWin::ensureWeekDayShortLabels()
 {
     if (!m_weekDayShortLabels.isEmpty())
@@ -379,6 +386,7 @@ void LocaleWin::ensureWeekDayShortLabels()
         }
     }
 }
+#endif
 
 #if ENABLE(DATE_AND_TIME_INPUT_TYPES)
 const Vector<String>& LocaleWin::monthLabels()