diff options
author | avi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-27 14:10:45 +0000 |
---|---|---|
committer | avi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-27 14:10:45 +0000 |
commit | a670807be316afb07951dbd2e05ef3d5680fe005 (patch) | |
tree | 49459187940625ac2bedcad98285adad622b0b2f /content/shell | |
parent | f5b95ba9948b4ed8d723eecc1360b4a4c7201187 (diff) | |
download | chromium_src-a670807be316afb07951dbd2e05ef3d5680fe005.zip chromium_src-a670807be316afb07951dbd2e05ef3d5680fe005.tar.gz chromium_src-a670807be316afb07951dbd2e05ef3d5680fe005.tar.bz2 |
Content shell: Switch to scoped resetter.
BUG=90445
TEST=none
Review URL: https://chromiumcodereview.appspot.com/9809026
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@129182 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/shell')
-rw-r--r-- | content/shell/shell_application_mac.mm | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/content/shell/shell_application_mac.mm b/content/shell/shell_application_mac.mm index 8e816aa..c8a6163 100644 --- a/content/shell/shell_application_mac.mm +++ b/content/shell/shell_application_mac.mm @@ -4,6 +4,8 @@ #include "content/shell/shell_application_mac.h" +#include "base/auto_reset.h" + @implementation ShellCrApplication - (BOOL)isHandlingSendEvent { @@ -11,10 +13,8 @@ } - (void)sendEvent:(NSEvent*)event { - BOOL wasHandlingSendEvent = handlingSendEvent_; - handlingSendEvent_ = YES; + AutoReset<BOOL> scoper(&handlingSendEvent_, YES); [super sendEvent:event]; - handlingSendEvent_ = wasHandlingSendEvent; } - (void)setHandlingSendEvent:(BOOL)handlingSendEvent { |