Chromium Code Reviews| Index: chrome/browser/ui/webui/ntp/new_tab_page_handler.cc |
| diff --git a/chrome/browser/ui/webui/ntp/new_tab_page_handler.cc b/chrome/browser/ui/webui/ntp/new_tab_page_handler.cc |
| index e9ee7bfabdf04538a8b54ee01d522d3979da30a8..54b53192c2e5be47df24b8a5fd647df771991138 100644 |
| --- a/chrome/browser/ui/webui/ntp/new_tab_page_handler.cc |
| +++ b/chrome/browser/ui/webui/ntp/new_tab_page_handler.cc |
| @@ -23,6 +23,10 @@ |
| #include "grit/generated_resources.h" |
| #include "ui/base/l10n/l10n_util.h" |
| +#if defined(OS_MACOSX) |
|
Patrick Dubroy
2012/04/16 21:27:59
Whoops. There should be no changes in this file.
|
| +#include "base/mac/mac_util.h" |
| +#endif |
| + |
| static const int kIntroDisplayMax = 10; |
| // The URL of a knowledge-base article about the new NTP. |
| @@ -190,6 +194,19 @@ void NewTabPageHandler::GetLocalizedValues(Profile* profile, |
| l10n_util::GetStringUTF16(IDS_LEARN_MORE)); |
| } |
| #endif |
| + |
| + LOG(WARNING) << "*********** ntp load"; |
| + |
| + // On Mac OS X 10.7+, horizontal scrolling can be treated as a back or |
| + // forward gesture. Pass through a flag that indicates whether or not that |
| + // feature is enabled. |
| +#if defined(OS_MACOSX) |
| + values->SetBoolean("isSwipeTrackingFromScrollEventsEnabled", |
| + base::mac::IsSwipeTrackingFromScrollEventsEnabled()); |
| +#else |
| + values->SetBoolean("isSwipeTrackingFromScrollEventsEnabled", |
| + false); |
| +#endif |
| } |
| // static |