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

Side by Side Diff: chrome/browser/resources/print_preview/data/cloud_parsers.js

Issue 574193002: Compile print_preview, part 1: remove all warnings (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@true_master
Patch Set: rebase 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 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 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 cr.define('cloudprint', function() { 5 cr.define('cloudprint', function() {
6 'use strict'; 6 'use strict';
7 7
8 /** Namespace which contains a method to parse cloud destinations directly. */ 8 /** Namespace which contains a method to parse cloud destinations directly. */
9 function CloudDestinationParser() {}; 9 function CloudDestinationParser() {};
10 10
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 var cloudDest = new print_preview.Destination( 88 var cloudDest = new print_preview.Destination(
89 id, 89 id,
90 CloudDestinationParser.parseType_( 90 CloudDestinationParser.parseType_(
91 json[CloudDestinationParser.Field_.TYPE]), 91 json[CloudDestinationParser.Field_.TYPE]),
92 origin, 92 origin,
93 json[CloudDestinationParser.Field_.DISPLAY_NAME], 93 json[CloudDestinationParser.Field_.DISPLAY_NAME],
94 arrayContains(tags, CloudDestinationParser.RECENT_TAG_) /*isRecent*/, 94 arrayContains(tags, CloudDestinationParser.RECENT_TAG_) /*isRecent*/,
95 connectionStatus, 95 connectionStatus,
96 optionalParams); 96 optionalParams);
97 if (json.hasOwnProperty(CloudDestinationParser.Field_.CAPABILITIES)) { 97 if (json.hasOwnProperty(CloudDestinationParser.Field_.CAPABILITIES)) {
98 cloudDest.capabilities = /*@type {!print_preview.Cdd}*/ ( 98 cloudDest.capabilities = /** @type {!print_preview.Cdd} */(
99 json[CloudDestinationParser.Field_.CAPABILITIES]); 99 json[CloudDestinationParser.Field_.CAPABILITIES]);
100 } 100 }
101 return cloudDest; 101 return cloudDest;
102 }; 102 };
103 103
104 /** 104 /**
105 * Parses the destination type. 105 * Parses the destination type.
106 * @param {string} typeStr Destination type given by the Google Cloud Print 106 * @param {string} typeStr Destination type given by the Google Cloud Print
107 * server. 107 * server.
108 * @return {!print_preview.Destination.Type} Destination type. 108 * @return {!print_preview.Destination.Type} Destination type.
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 return new print_preview.Invitation( 185 return new print_preview.Invitation(
186 senderName, receiverName, destination, receiver, account); 186 senderName, receiverName, destination, receiver, account);
187 }; 187 };
188 188
189 // Export 189 // Export
190 return { 190 return {
191 CloudDestinationParser: CloudDestinationParser, 191 CloudDestinationParser: CloudDestinationParser,
192 InvitationParser: InvitationParser 192 InvitationParser: InvitationParser
193 }; 193 };
194 }); 194 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698