Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(324)

Side by Side Diff: Source/WebKit/chromium/src/WebScrollbarImpl.cpp

Issue 7248010: Merge 89584 - 2011-06-23 John Abd-El-Malek <jam@chromium.org> (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/782/
Patch Set: Created 9 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/WebKit/chromium/src/WebScrollbarImpl.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 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 296 matching lines...) Expand 10 before | Expand all | Expand 10 after
307 Scrollbar* WebScrollbarImpl::horizontalScrollbar() const 307 Scrollbar* WebScrollbarImpl::horizontalScrollbar() const
308 { 308 {
309 return m_scrollbar->orientation() == HorizontalScrollbar ? m_scrollbar.get() : 0; 309 return m_scrollbar->orientation() == HorizontalScrollbar ? m_scrollbar.get() : 0;
310 } 310 }
311 311
312 Scrollbar* WebScrollbarImpl::verticalScrollbar() const 312 Scrollbar* WebScrollbarImpl::verticalScrollbar() const
313 { 313 {
314 return m_scrollbar->orientation() == VerticalScrollbar ? m_scrollbar.get() : 0; 314 return m_scrollbar->orientation() == VerticalScrollbar ? m_scrollbar.get() : 0;
315 } 315 }
316 316
317 int WebScrollbarImpl::visibleHeight() const
318 {
319 return m_scrollbar->height();
320 }
321
322 int WebScrollbarImpl::visibleWidth() const
323 {
324 return m_scrollbar->width();
325 }
326
327 IntSize WebScrollbarImpl::contentsSize() const
328 {
329 // This isn't technically correct, since we don't have the contentSize. Howe ver it's good enough
330 // to make the ScrollAnimator code happy.
331 int thickness = defaultThickness();
332 int length = m_scrollbar->totalSize();
333 return m_scrollbar->orientation() == VerticalScrollbar ? IntSize(thickness, length) : IntSize(length, thickness);
334 }
335
336 IntSize WebScrollbarImpl::overhangAmount() const
337 {
338 return IntSize();
339 }
340
317 } // namespace WebKit 341 } // namespace WebKit
OLDNEW
« no previous file with comments | « Source/WebKit/chromium/src/WebScrollbarImpl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698