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

Side by Side Diff: Source/platform/mac/ThemeMac.h

Issue 641733004: Merge FrameView and ScrollView. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebaseline. Created 6 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « Source/platform/mac/ScrollAnimatorMac.mm ('k') | Source/platform/mac/ThemeMac.mm » ('j') | 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) 2008 Apple Inc. All Rights Reserved. 2 * Copyright (C) 2008 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 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 virtual FontDescription controlFont(ControlPart, const FontDescription&, flo at zoomFactor) const; 44 virtual FontDescription controlFont(ControlPart, const FontDescription&, flo at zoomFactor) const;
45 45
46 virtual LengthSize controlSize(ControlPart, const FontDescription&, const Le ngthSize&, float zoomFactor) const; 46 virtual LengthSize controlSize(ControlPart, const FontDescription&, const Le ngthSize&, float zoomFactor) const;
47 virtual LengthSize minimumControlSize(ControlPart, const FontDescription&, f loat zoomFactor) const; 47 virtual LengthSize minimumControlSize(ControlPart, const FontDescription&, f loat zoomFactor) const;
48 48
49 virtual LengthBox controlPadding(ControlPart, const FontDescription&, const LengthBox& zoomedBox, float zoomFactor) const; 49 virtual LengthBox controlPadding(ControlPart, const FontDescription&, const LengthBox& zoomedBox, float zoomFactor) const;
50 virtual LengthBox controlBorder(ControlPart, const FontDescription&, const L engthBox& zoomedBox, float zoomFactor) const; 50 virtual LengthBox controlBorder(ControlPart, const FontDescription&, const L engthBox& zoomedBox, float zoomFactor) const;
51 51
52 virtual bool controlRequiresPreWhiteSpace(ControlPart part) const { return p art == PushButtonPart; } 52 virtual bool controlRequiresPreWhiteSpace(ControlPart part) const { return p art == PushButtonPart; }
53 53
54 virtual void paint(ControlPart, ControlStates, GraphicsContext*, const IntRe ct&, float zoomFactor, ScrollView*) const; 54 virtual void paint(ControlPart, ControlStates, GraphicsContext*, const IntRe ct&, float zoomFactor, ScrollableArea*) const;
55 virtual void inflateControlPaintRect(ControlPart, ControlStates, IntRect&, f loat zoomFactor) const; 55 virtual void inflateControlPaintRect(ControlPart, ControlStates, IntRect&, f loat zoomFactor) const;
56 56
57 // Inflate an IntRect to accout for specific padding around margins. 57 // Inflate an IntRect to accout for specific padding around margins.
58 enum { 58 enum {
59 TopMargin = 0, 59 TopMargin = 0,
60 RightMargin = 1, 60 RightMargin = 1,
61 BottomMargin = 2, 61 BottomMargin = 2,
62 LeftMargin = 3 62 LeftMargin = 3
63 }; 63 };
64 static PLATFORM_EXPORT IntRect inflateRect(const IntRect&, const IntSize&, c onst int* margins, float zoomLevel = 1.0f); 64 static PLATFORM_EXPORT IntRect inflateRect(const IntRect&, const IntSize&, c onst int* margins, float zoomLevel = 1.0f);
65 65
66 // Inflate an IntRect to account for any bleeding that would happen due to a nti-aliasing. 66 // Inflate an IntRect to account for any bleeding that would happen due to a nti-aliasing.
67 static PLATFORM_EXPORT IntRect inflateRectForAA(const IntRect&); 67 static PLATFORM_EXPORT IntRect inflateRectForAA(const IntRect&);
68 68
69 // Inflate an IntRect to account for its focus ring. This is only used when 69 // Inflate an IntRect to account for its focus ring. This is only used when
70 // BUTTON_CELL_DRAW_WITH_FRAME_DRAWS_FOCUS_RING is defined (otherwise, the f ocus ring's 70 // BUTTON_CELL_DRAW_WITH_FRAME_DRAWS_FOCUS_RING is defined (otherwise, the f ocus ring's
71 // bounds could be accurately computed with -[NSCell focusRingMaskBoundsForF rame:inView:]). 71 // bounds could be accurately computed with -[NSCell focusRingMaskBoundsForF rame:inView:]).
72 static PLATFORM_EXPORT IntRect inflateRectForFocusRing(const IntRect&); 72 static PLATFORM_EXPORT IntRect inflateRectForFocusRing(const IntRect&);
73 73
74 // FIXME: Once RenderThemeMac is converted over to use Theme then this can b e internal to ThemeMac. 74 // FIXME: Once RenderThemeMac is converted over to use Theme then this can b e internal to ThemeMac.
75 static NSView* ensuredView(ScrollView*); 75 static NSView* ensuredView(ScrollableArea*);
76 static void setFocusRingClipRect(const FloatRect&); 76 static void setFocusRingClipRect(const FloatRect&);
77 }; 77 };
78 78
79 } // namespace blink 79 } // namespace blink
80 80
81 #endif // ThemeMac_h 81 #endif // ThemeMac_h
OLDNEW
« no previous file with comments | « Source/platform/mac/ScrollAnimatorMac.mm ('k') | Source/platform/mac/ThemeMac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698