| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights | 3 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights |
| 4 * reserved. | 4 * reserved. |
| 5 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 5 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
| 6 * Copyright (C) 2012 Digia Plc. and/or its subsidiary(-ies) | 6 * Copyright (C) 2012 Digia Plc. and/or its subsidiary(-ies) |
| 7 * | 7 * |
| 8 * Redistribution and use in source and binary forms, with or without | 8 * Redistribution and use in source and binary forms, with or without |
| 9 * modification, are permitted provided that the following conditions | 9 * modification, are permitted provided that the following conditions |
| 10 * are met: | 10 * are met: |
| (...skipping 26 matching lines...) Expand all Loading... |
| 37 #include "core/layout/LayoutBox.h" | 37 #include "core/layout/LayoutBox.h" |
| 38 #include "core/layout/LayoutListBox.h" | 38 #include "core/layout/LayoutListBox.h" |
| 39 #include "core/page/ChromeClient.h" | 39 #include "core/page/ChromeClient.h" |
| 40 #include "core/page/Page.h" | 40 #include "core/page/Page.h" |
| 41 #include "platform/wtf/Time.h" | 41 #include "platform/wtf/Time.h" |
| 42 | 42 |
| 43 namespace blink { | 43 namespace blink { |
| 44 | 44 |
| 45 // Delay time in second for start autoscroll if pointer is in border edge of | 45 // Delay time in second for start autoscroll if pointer is in border edge of |
| 46 // scrollable element. | 46 // scrollable element. |
| 47 static const TimeDelta kAutoscrollDelay = TimeDelta::FromSecondsD(0.2); | 47 constexpr TimeDelta kAutoscrollDelay = TimeDelta::FromSecondsD(0.2); |
| 48 | 48 |
| 49 AutoscrollController* AutoscrollController::Create(Page& page) { | 49 AutoscrollController* AutoscrollController::Create(Page& page) { |
| 50 return new AutoscrollController(page); | 50 return new AutoscrollController(page); |
| 51 } | 51 } |
| 52 | 52 |
| 53 AutoscrollController::AutoscrollController(Page& page) | 53 AutoscrollController::AutoscrollController(Page& page) |
| 54 : page_(&page), | 54 : page_(&page), |
| 55 autoscroll_layout_object_(nullptr), | 55 autoscroll_layout_object_(nullptr), |
| 56 pressed_layout_object_(nullptr), | 56 pressed_layout_object_(nullptr), |
| 57 autoscroll_type_(kNoAutoscroll), | 57 autoscroll_type_(kNoAutoscroll), |
| (...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 412 } else if (east) { | 412 } else if (east) { |
| 413 view->SetCursor(EastPanningCursor()); | 413 view->SetCursor(EastPanningCursor()); |
| 414 } else if (west) { | 414 } else if (west) { |
| 415 view->SetCursor(WestPanningCursor()); | 415 view->SetCursor(WestPanningCursor()); |
| 416 } else { | 416 } else { |
| 417 view->SetCursor(MiddlePanningCursor()); | 417 view->SetCursor(MiddlePanningCursor()); |
| 418 } | 418 } |
| 419 } | 419 } |
| 420 | 420 |
| 421 } // namespace blink | 421 } // namespace blink |
| OLD | NEW |