| 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 230 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 241 if (!m_widget) | 241 if (!m_widget) |
| 242 return; | 242 return; |
| 243 | 243 |
| 244 if (!rect.isEmpty()) { | 244 if (!rect.isEmpty()) { |
| 245 GraphicsContext context(canvas, | 245 GraphicsContext context(canvas, |
| 246 contextStatus == WebContentLayerClient::GraphicsContextEnabled ? Gra
phicsContext::NothingDisabled : GraphicsContext::FullyDisabled); | 246 contextStatus == WebContentLayerClient::GraphicsContextEnabled ? Gra
phicsContext::NothingDisabled : GraphicsContext::FullyDisabled); |
| 247 m_widget->paint(&context, rect); | 247 m_widget->paint(&context, rect); |
| 248 } | 248 } |
| 249 } | 249 } |
| 250 | 250 |
| 251 void WebPopupMenuImpl::paint(WebCanvas* canvas, const WebRect& rect, PaintOption
s) | 251 void WebPopupMenuImpl::paint(WebCanvas* canvas, const WebRect& rect) |
| 252 { | 252 { |
| 253 if (!m_widget) | 253 if (!m_widget) |
| 254 return; | 254 return; |
| 255 | 255 |
| 256 if (!rect.isEmpty()) { | 256 if (!rect.isEmpty()) { |
| 257 GraphicsContext context(canvas); | 257 GraphicsContext context(canvas); |
| 258 context.applyDeviceScaleFactor(m_client->deviceScaleFactor()); | 258 context.applyDeviceScaleFactor(m_client->deviceScaleFactor()); |
| 259 m_widget->paint(&context, rect); | 259 m_widget->paint(&context, rect); |
| 260 } | 260 } |
| 261 } | 261 } |
| (...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 441 ASSERT(widget == m_widget); | 441 ASSERT(widget == m_widget); |
| 442 if (m_widget) { | 442 if (m_widget) { |
| 443 m_widget->setClient(0); | 443 m_widget->setClient(0); |
| 444 m_widget = 0; | 444 m_widget = 0; |
| 445 } | 445 } |
| 446 if (m_client) | 446 if (m_client) |
| 447 m_client->closeWidgetSoon(); | 447 m_client->closeWidgetSoon(); |
| 448 } | 448 } |
| 449 | 449 |
| 450 } // namespace blink | 450 } // namespace blink |
| OLD | NEW |