Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(300)

Side by Side Diff: Source/web/EditorClientImpl.cpp

Issue 23672027: Rename OS(WINDOWS) to OS(WIN) (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/core/rendering/RenderThemeChromiumDefault.cpp ('k') | Source/web/WebFrameImpl.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007 Apple, Inc. All rights reserved. 2 * Copyright (C) 2006, 2007 Apple, Inc. All rights reserved.
3 * Copyright (C) 2012 Google, Inc. All rights reserved. 3 * Copyright (C) 2012 Google, Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 575 matching lines...) Expand 10 before | Expand all | Expand 10 after
586 // which may be configured to do it so by user. 586 // which may be configured to do it so by user.
587 // See also http://en.wikipedia.org/wiki/Keyboard_Layout 587 // See also http://en.wikipedia.org/wiki/Keyboard_Layout
588 // FIXME(ukai): investigate more detail for various keyboard layout. 588 // FIXME(ukai): investigate more detail for various keyboard layout.
589 if (evt->keyEvent()->text().length() == 1) { 589 if (evt->keyEvent()->text().length() == 1) {
590 UChar ch = evt->keyEvent()->text()[0U]; 590 UChar ch = evt->keyEvent()->text()[0U];
591 591
592 // Don't insert null or control characters as they can result in 592 // Don't insert null or control characters as they can result in
593 // unexpected behaviour 593 // unexpected behaviour
594 if (ch < ' ') 594 if (ch < ' ')
595 return false; 595 return false;
596 #if !OS(WINDOWS) 596 #if !OS(WIN)
597 // Don't insert ASCII character if ctrl w/o alt or meta is on. 597 // Don't insert ASCII character if ctrl w/o alt or meta is on.
598 // On Mac, we should ignore events when meta is on (Command-<x>). 598 // On Mac, we should ignore events when meta is on (Command-<x>).
599 if (ch < 0x80) { 599 if (ch < 0x80) {
600 if (evt->keyEvent()->ctrlKey() && !evt->keyEvent()->altKey()) 600 if (evt->keyEvent()->ctrlKey() && !evt->keyEvent()->altKey())
601 return false; 601 return false;
602 #if OS(MACOSX) 602 #if OS(MACOSX)
603 if (evt->keyEvent()->metaKey()) 603 if (evt->keyEvent()->metaKey())
604 return false; 604 return false;
605 #endif 605 #endif
606 } 606 }
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after
776 #endif 776 #endif
777 } 777 }
778 778
779 void EditorClientImpl::willSetInputMethodState() 779 void EditorClientImpl::willSetInputMethodState()
780 { 780 {
781 if (m_webView->client()) 781 if (m_webView->client())
782 m_webView->client()->resetInputMethod(); 782 m_webView->client()->resetInputMethod();
783 } 783 }
784 784
785 } // namesace WebKit 785 } // namesace WebKit
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderThemeChromiumDefault.cpp ('k') | Source/web/WebFrameImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698