| OLD | NEW |
| (Empty) | |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "chrome/browser/thumbnails/thumbnailing_context.h" |
| 6 |
| 7 #include "content/public/browser/render_view_host.h" |
| 8 |
| 9 namespace thumbnails { |
| 10 |
| 11 ThumbnailingContext::ThumbnailingContext( |
| 12 content::WebContents* web_contents, |
| 13 bool load_interrupted) |
| 14 : browser_context(web_contents->GetBrowserContext()), |
| 15 url(web_contents->GetURL()), |
| 16 clip_result(kUnprocessed) { |
| 17 score.at_top = |
| 18 (web_contents->GetRenderViewHost()->GetLastScrollOffset().y() == 0); |
| 19 score.load_completed = !web_contents->IsLoading() && !load_interrupted; |
| 20 } |
| 21 |
| 22 ThumbnailingContext::~ThumbnailingContext() { |
| 23 } |
| 24 |
| 25 } |
| OLD | NEW |