| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2011 Apple 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 | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 163 } else if (backButtonRect(scrollbar, BackButtonEndPart).contains(testPositio
n)) { | 163 } else if (backButtonRect(scrollbar, BackButtonEndPart).contains(testPositio
n)) { |
| 164 result = BackButtonEndPart; | 164 result = BackButtonEndPart; |
| 165 } else if (forwardButtonRect(scrollbar, ForwardButtonStartPart).contains(tes
tPosition)) { | 165 } else if (forwardButtonRect(scrollbar, ForwardButtonStartPart).contains(tes
tPosition)) { |
| 166 result = ForwardButtonStartPart; | 166 result = ForwardButtonStartPart; |
| 167 } else if (forwardButtonRect(scrollbar, ForwardButtonEndPart).contains(testP
osition)) { | 167 } else if (forwardButtonRect(scrollbar, ForwardButtonEndPart).contains(testP
osition)) { |
| 168 result = ForwardButtonEndPart; | 168 result = ForwardButtonEndPart; |
| 169 } | 169 } |
| 170 return result; | 170 return result; |
| 171 } | 171 } |
| 172 | 172 |
| 173 void ScrollbarTheme::paintScrollCorner(GraphicsContext* context, const DisplayIt
emClientWrapper& displayItemClient, const IntRect& cornerRect) | 173 void ScrollbarTheme::paintScrollCorner(GraphicsContext* context, const DisplayIt
emClient& displayItemClient, const IntRect& cornerRect) |
| 174 { | 174 { |
| 175 if (cornerRect.isEmpty()) | 175 if (cornerRect.isEmpty()) |
| 176 return; | 176 return; |
| 177 | 177 |
| 178 if (DrawingRecorder::useCachedDrawingIfPossible(*context, displayItemClient,
DisplayItem::ScrollbarCorner)) | 178 if (DrawingRecorder::useCachedDrawingIfPossible(*context, displayItemClient,
DisplayItem::ScrollbarCorner)) |
| 179 return; | 179 return; |
| 180 | 180 |
| 181 DrawingRecorder recorder(*context, displayItemClient, DisplayItem::Scrollbar
Corner, cornerRect); | 181 DrawingRecorder recorder(*context, displayItemClient, DisplayItem::Scrollbar
Corner, cornerRect); |
| 182 #if OS(MACOSX) | 182 #if OS(MACOSX) |
| 183 context->fillRect(cornerRect, Color::white); | 183 context->fillRect(cornerRect, Color::white); |
| (...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 332 return DisplayItem::ScrollbarBackTrack; | 332 return DisplayItem::ScrollbarBackTrack; |
| 333 case ForwardTrackPart: | 333 case ForwardTrackPart: |
| 334 return DisplayItem::ScrollbarForwardTrack; | 334 return DisplayItem::ScrollbarForwardTrack; |
| 335 default: | 335 default: |
| 336 ASSERT_NOT_REACHED(); | 336 ASSERT_NOT_REACHED(); |
| 337 return DisplayItem::ScrollbarBackTrack; | 337 return DisplayItem::ScrollbarBackTrack; |
| 338 } | 338 } |
| 339 } | 339 } |
| 340 | 340 |
| 341 } // namespace blink | 341 } // namespace blink |
| OLD | NEW |