Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef CHROME_BROWSER_INTENTS_WEB_INTENT_SERVICE_DATA_H_ | 5 #ifndef CHROME_BROWSER_INTENTS_WEB_INTENT_SERVICE_DATA_H_ |
|
tony
2011/09/22 18:47:42
Nit: Please update the include guard.
groby-ooo-7-16
2011/09/23 22:29:53
Done.
| |
| 6 #define CHROME_BROWSER_INTENTS_WEB_INTENT_SERVICE_DATA_H_ | 6 #define CHROME_BROWSER_INTENTS_WEB_INTENT_SERVICE_DATA_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/string16.h" | 9 #include "base/string16.h" |
| 10 #include "googleurl/src/gurl.h" | 10 #include "googleurl/src/gurl.h" |
| 11 #include <iosfwd> | 11 #include <iosfwd> |
| 12 | 12 |
| 13 // Describes the relevant elements of a WebIntent service. | 13 // Describes the relevant elements of a WebIntent service. |
| 14 // TODO(gbillock): if we want to use this in an IPC message, it should | 14 // TODO(gbillock): if we want to use this in an IPC message, it should |
| 15 // go in webkit/glue in web_intent_data. | 15 // go in webkit/glue in web_intent_data. |
|
tony
2011/09/22 18:47:42
Looks like we can remove this comment.
groby-ooo-7-16
2011/09/23 22:29:53
Done.
| |
| 16 struct WebIntentServiceData { | 16 struct WebIntentServiceData { |
| 17 // An intents disposition determines which context the service is opened in. | 17 // An intents disposition determines which context the service is opened in. |
| 18 enum Disposition { | 18 enum Disposition { |
| 19 DISPOSITION_WINDOW, // Open service inside a new window. (Default) | 19 DISPOSITION_WINDOW, // Open service inside a new window. (Default) |
| 20 DISPOSITION_INLINE, // Open service inside the picker UI window. | 20 DISPOSITION_INLINE, // Open service inside the picker UI window. |
| 21 }; | 21 }; |
| 22 | 22 |
| 23 WebIntentServiceData(); | 23 WebIntentServiceData(); |
| 24 ~WebIntentServiceData(); | 24 ~WebIntentServiceData(); |
| 25 | 25 |
| 26 bool operator==(const WebIntentServiceData& other) const; | 26 bool operator==(const WebIntentServiceData& other) const; |
| 27 | 27 |
| 28 GURL service_url; // URL for service invocation. | 28 GURL service_url; // URL for service invocation. |
| 29 string16 action; // Name of action provided by service. | 29 string16 action; // Name of action provided by service. |
| 30 string16 type; // MIME type of data accepted by service. | 30 string16 type; // MIME type of data accepted by service. |
| 31 string16 title; // The title of the service. | 31 string16 title; // The title of the service. |
| 32 Disposition disposition; // The context the service is opened in. | 32 Disposition disposition; // The context the service is opened in. |
| 33 }; | 33 }; |
| 34 | 34 |
| 35 // Printing operator - helps gtest produce readable error messages. | 35 // Printing operator - helps gtest produce readable error messages. |
| 36 std::ostream& operator<<(std::ostream& os, const WebIntentServiceData& intent); | 36 std::ostream& operator<<(std::ostream& os, const WebIntentServiceData& intent); |
| 37 | 37 |
| 38 #endif // CHROME_BROWSER_INTENTS_WEB_INTENT_SERVICE_DATA_H_ | 38 #endif // CHROME_BROWSER_INTENTS_WEB_INTENT_SERVICE_DATA_H_ |
| OLD | NEW |