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

Side by Side Diff: sync/protocol/session_specifics.proto

Issue 2130453004: [Sync] Move //sync to //components/sync. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 years, 4 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 | « sync/protocol/search_engine_specifics.proto ('k') | sync/protocol/sync.proto » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2012 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 // Sync protocol datatype extension for sessions.
6
7 // Update proto_value_conversions{.h,.cc,_unittest.cc} if you change
8 // any fields in this file.
9
10 syntax = "proto2";
11
12 option optimize_for = LITE_RUNTIME;
13 option retain_unknown_fields = true;
14
15 package sync_pb;
16
17 import "sync_enums.proto";
18
19 message SessionSpecifics {
20 // Unique id for the client.
21 optional string session_tag = 1;
22 optional SessionHeader header = 2;
23 optional SessionTab tab = 3;
24
25 // The local tab id used by sync. Unique across all nodes for that client.
26 optional int32 tab_node_id = 4 [default = -1];
27 }
28
29 // Properties of session sync objects.
30 message SessionHeader {
31 // Each session is composed of windows.
32 repeated SessionWindow window = 2;
33 // A non-unique but human-readable name to describe this client.
34 optional string client_name = 3;
35 // The type of device.
36 optional SyncEnums.DeviceType device_type = 4;
37 }
38
39 message SessionWindow {
40 // Unique (to the owner) id for this window.
41 optional int32 window_id = 1;
42 // Index of the selected tab in tabs; -1 if no tab is selected.
43 optional int32 selected_tab_index = 2 [default = -1];
44 // Type of the browser. Currently we only store browsers of type
45 // TYPE_TABBED and TYPE_POPUP.
46 enum BrowserType {
47 TYPE_TABBED = 1;
48 TYPE_POPUP = 2;
49 }
50 optional BrowserType browser_type = 3 [default = TYPE_TABBED];
51 // The tabs that compose a window (correspond to tab id's).
52 repeated int32 tab = 4;
53 }
54
55 message SessionTab {
56 // Unique (to the owner) id for this tab.
57 optional int32 tab_id = 1;
58 // The unique id for the window this tab belongs to.
59 optional int32 window_id = 2;
60 // Visual index of the tab within its window. There may be gaps in these
61 // values.
62 optional int32 tab_visual_index = 3 [default = -1];
63 // Identifies the index of the current navigation in navigations. For
64 // example, if this is 2 it means the current navigation is navigations[2].
65 optional int32 current_navigation_index = 4 [default = -1];
66 // True if the tab is pinned.
67 optional bool pinned = 5 [default = false];
68 // If non-empty, this tab is an app tab and this is the id of the extension.
69 optional string extension_app_id = 6;
70 // Tabs are navigated, and the navigation data is here.
71 repeated TabNavigation navigation = 7;
72
73 // Fields 8 through 11 are deprecated.
74 // The favicon for the current url the tab is displaying. Either empty
75 // or a valid PNG encoded favicon.
76 optional bytes favicon = 8;
77 // The type of favicon. For now only normal web favicons are supported.
78 enum FaviconType {
79 TYPE_WEB_FAVICON = 1;
80 }
81 optional FaviconType favicon_type = 9;
82 // The url of the actual favicon (as opposed to the page using the favicon).
83 optional string favicon_source = 11;
84 // Ids of the currently assigned variations which should be sent to sync.
85 repeated uint64 variation_id = 12;
86 }
87
88 message TabNavigation {
89 // The index in the NavigationController. If this is -1, it means this
90 // TabNavigation is bogus.
91 // optional int32 index = 1 [default = -1]; // obsolete.
92 // The virtual URL, when nonempty, will override the actual URL of the page
93 // when we display it to the user.
94 optional string virtual_url = 2;
95 // The referring URL, which can be empty.
96 optional string referrer = 3;
97 // The title of the page.
98 optional string title = 4;
99 // Content state is an opaque blob created by WebKit that represents the
100 // state of the page. This includes form entries and scroll position for each
101 // frame.
102 // optional string state = 5; // obsolete.
103 // The core transition type.
104 optional SyncEnums.PageTransition page_transition = 6 [default = TYPED];
105 // If this transition was triggered by a redirect, the redirect type.
106 optional SyncEnums.PageTransitionRedirectType redirect_type = 7;
107 // The unique navigation id (within this client).
108 optional int32 unique_id = 8;
109 // Timestamp for when this navigation last occurred (in client time).
110 // If the user goes back/foward in history the timestamp may refresh.
111 optional int64 timestamp_msec = 9;
112 // User used the Forward or Back button to navigate among browsing history.
113 optional bool navigation_forward_back = 10;
114 // User used the address bar to trigger this navigation.
115 optional bool navigation_from_address_bar = 11;
116 // User is navigating to the home page.
117 optional bool navigation_home_page = 12;
118 // The beginning of a navigation chain.
119 optional bool navigation_chain_start = 13;
120 // The last transition in a redirect chain.
121 optional bool navigation_chain_end = 14;
122 // The id for this navigation, which is globally unique with high
123 // probability.
124 optional int64 global_id = 15;
125 // Search terms extracted from the URL.
126 optional string search_terms = 16;
127 // The favicon url associated with this page.
128 optional string favicon_url = 17;
129 enum BlockedState {
130 STATE_ALLOWED = 1;
131 STATE_BLOCKED = 2;
132 }
133 // Whether access to the URL was allowed or blocked.
134 optional BlockedState blocked_state = 18 [default=STATE_ALLOWED];
135 // A list of category identifiers for the URL.
136 repeated string content_pack_categories = 19;
137 // The status code from the last navigation.
138 optional int32 http_status_code = 20;
139
140 // Referrer policy. Old, broken value.
141 optional int32 obsolete_referrer_policy = 21 [default = 1];
142 // True if created from restored navigation entry that hasn't been loaded.
143 optional bool is_restored = 22;
144 // The chain of redirections for this navigation, from the original URL
145 // through the last URL that redirected.
146 repeated NavigationRedirect navigation_redirect = 23;
147 // Normally not present.
148 // The last URL traversed when different from the virtual_url.
149 optional string last_navigation_redirect_url = 24;
150 // Correct referrer policy. Valid enums are defined in
151 // third_party/WebKit/public/platform/WebReferrerPolicy.h.
152 optional int32 correct_referrer_policy = 25 [default = 1];
153 }
154
155 // Navigation information for a single redirection within a single navigation.
156 message NavigationRedirect {
157 // A URL that redirected while navigating to the virtual_url.
158 optional string url = 1;
159 }
OLDNEW
« no previous file with comments | « sync/protocol/search_engine_specifics.proto ('k') | sync/protocol/sync.proto » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698