OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 1217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1228 TRACE_EVENT0("blink", "WebLocalFrameImpl::setCompositionFromExistingText"); | 1228 TRACE_EVENT0("blink", "WebLocalFrameImpl::setCompositionFromExistingText"); |
1229 if (!frame()->editor().canEdit()) | 1229 if (!frame()->editor().canEdit()) |
1230 return false; | 1230 return false; |
1231 | 1231 |
1232 InputMethodController& inputMethodController = frame()->inputMethodControlle
r(); | 1232 InputMethodController& inputMethodController = frame()->inputMethodControlle
r(); |
1233 inputMethodController.cancelComposition(); | 1233 inputMethodController.cancelComposition(); |
1234 | 1234 |
1235 if (compositionStart == compositionEnd) | 1235 if (compositionStart == compositionEnd) |
1236 return true; | 1236 return true; |
1237 | 1237 |
| 1238 // TODO(xiaochengh): The use of updateStyleAndLayoutIgnorePendingStylesheets |
| 1239 // needs to be audited. See http://crbug.com/590369 for more details. |
| 1240 frame()->document()->updateStyleAndLayoutIgnorePendingStylesheets(); |
| 1241 |
1238 inputMethodController.setCompositionFromExistingText(CompositionUnderlineVec
torBuilder(underlines), compositionStart, compositionEnd); | 1242 inputMethodController.setCompositionFromExistingText(CompositionUnderlineVec
torBuilder(underlines), compositionStart, compositionEnd); |
1239 | 1243 |
1240 return true; | 1244 return true; |
1241 } | 1245 } |
1242 | 1246 |
1243 void WebLocalFrameImpl::extendSelectionAndDelete(int before, int after) | 1247 void WebLocalFrameImpl::extendSelectionAndDelete(int before, int after) |
1244 { | 1248 { |
1245 TRACE_EVENT0("blink", "WebLocalFrameImpl::extendSelectionAndDelete"); | 1249 TRACE_EVENT0("blink", "WebLocalFrameImpl::extendSelectionAndDelete"); |
1246 if (WebPlugin* plugin = focusedPluginIfInputMethodSupported()) { | 1250 if (WebPlugin* plugin = focusedPluginIfInputMethodSupported()) { |
1247 plugin->extendSelectionAndDelete(before, after); | 1251 plugin->extendSelectionAndDelete(before, after); |
(...skipping 974 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2222 feature = UseCounter::ChromeLoadTimesNpnNegotiatedProtocol; | 2226 feature = UseCounter::ChromeLoadTimesNpnNegotiatedProtocol; |
2223 } else if (metric == "wasAlternateProtocolAvailable") { | 2227 } else if (metric == "wasAlternateProtocolAvailable") { |
2224 feature = UseCounter::ChromeLoadTimesWasAlternateProtocolAvailable; | 2228 feature = UseCounter::ChromeLoadTimesWasAlternateProtocolAvailable; |
2225 } else if (metric == "connectionInfo") { | 2229 } else if (metric == "connectionInfo") { |
2226 feature = UseCounter::ChromeLoadTimesConnectionInfo; | 2230 feature = UseCounter::ChromeLoadTimesConnectionInfo; |
2227 } | 2231 } |
2228 UseCounter::count(frame(), feature); | 2232 UseCounter::count(frame(), feature); |
2229 } | 2233 } |
2230 | 2234 |
2231 } // namespace blink | 2235 } // namespace blink |
OLD | NEW |