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

Side by Side Diff: android_webview/common/print_messages.h

Issue 605123003: Apply automatic range checks to storage enum types across IPC in android_webview (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Chanages as per coding style 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
« no previous file with comments | « no previous file | 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 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // IPC messages for printing. 5 // IPC messages for printing.
6 // Multiply-included message file, hence no include guard. 6 // Multiply-included message file, hence no include guard.
7 7
8 // TODO(sgurun) copied from chrome/common. Remove after crbug.com/322276 8 // TODO(sgurun) copied from chrome/common. Remove after crbug.com/322276
9 9
10 #include <string> 10 #include <string>
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 bool is_modifiable; 70 bool is_modifiable;
71 bool webnode_only; 71 bool webnode_only;
72 bool has_selection; 72 bool has_selection;
73 bool selection_only; 73 bool selection_only;
74 }; 74 };
75 75
76 #endif // AW_COMMON_PRINT_MESSAGES_H_ 76 #endif // AW_COMMON_PRINT_MESSAGES_H_
77 77
78 #define IPC_MESSAGE_START PrintMsgStart 78 #define IPC_MESSAGE_START PrintMsgStart
79 79
80 IPC_ENUM_TRAITS(printing::MarginType) 80 IPC_ENUM_TRAITS_MAX_VALUE(printing::MarginType,
81 IPC_ENUM_TRAITS(blink::WebPrintScalingOption) 81 printing::iMarginType::MARGIN_TYPE_LAST)
nasko 2014/09/29 15:18:04 You have a typo in "iMarginType".
MRV 2014/09/30 02:52:47 Done.
82
83 IPC_ENUM_TRAITS_MAX_VALUE(
84 blink::WebPrintScalingOption,
85 blink::WebPrintScalingOption::WebPrintScalingOptionLast)
82 86
83 // Parameters for a render request. 87 // Parameters for a render request.
84 IPC_STRUCT_TRAITS_BEGIN(PrintMsg_Print_Params) 88 IPC_STRUCT_TRAITS_BEGIN(PrintMsg_Print_Params)
85 // Physical size of the page, including non-printable margins, 89 // Physical size of the page, including non-printable margins,
86 // in pixels according to dpi. 90 // in pixels according to dpi.
87 IPC_STRUCT_TRAITS_MEMBER(page_size) 91 IPC_STRUCT_TRAITS_MEMBER(page_size)
88 92
89 // In pixels according to dpi_x and dpi_y. 93 // In pixels according to dpi_x and dpi_y.
90 IPC_STRUCT_TRAITS_MEMBER(content_size) 94 IPC_STRUCT_TRAITS_MEMBER(content_size)
91 95
(...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after
435 IPC_SYNC_MESSAGE_ROUTED0_0(PrintHostMsg_SetupScriptedPrintPreview) 439 IPC_SYNC_MESSAGE_ROUTED0_0(PrintHostMsg_SetupScriptedPrintPreview)
436 440
437 // Tell the browser to show the print preview, when the document is sufficiently 441 // Tell the browser to show the print preview, when the document is sufficiently
438 // loaded such that the renderer can determine whether it is modifiable or not. 442 // loaded such that the renderer can determine whether it is modifiable or not.
439 IPC_MESSAGE_ROUTED1(PrintHostMsg_ShowScriptedPrintPreview, 443 IPC_MESSAGE_ROUTED1(PrintHostMsg_ShowScriptedPrintPreview,
440 bool /* is_modifiable */) 444 bool /* is_modifiable */)
441 445
442 // Notify the browser that the PDF in the initiator renderer has disabled print 446 // Notify the browser that the PDF in the initiator renderer has disabled print
443 // scaling option. 447 // scaling option.
444 IPC_MESSAGE_ROUTED0(PrintHostMsg_PrintPreviewScalingDisabled) 448 IPC_MESSAGE_ROUTED0(PrintHostMsg_PrintPreviewScalingDisabled)
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698