OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 #include "extensions/common/extension.h" | 5 #include "extensions/common/extension.h" |
6 | 6 |
7 #include "base/base64.h" | 7 #include "base/base64.h" |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
324 | 324 |
325 return web_extent().OverlapsWith(origin_only_pattern_list); | 325 return web_extent().OverlapsWith(origin_only_pattern_list); |
326 } | 326 } |
327 | 327 |
328 bool Extension::RequiresSortOrdinal() const { | 328 bool Extension::RequiresSortOrdinal() const { |
329 return is_app() && (display_in_launcher_ || display_in_new_tab_page_); | 329 return is_app() && (display_in_launcher_ || display_in_new_tab_page_); |
330 } | 330 } |
331 | 331 |
332 bool Extension::ShouldDisplayInAppLauncher() const { | 332 bool Extension::ShouldDisplayInAppLauncher() const { |
333 // Only apps should be displayed in the launcher. | 333 // Only apps should be displayed in the launcher. |
334 return is_app() && display_in_launcher_ && !is_ephemeral(); | 334 return is_app() && display_in_launcher_; |
335 } | 335 } |
336 | 336 |
337 bool Extension::ShouldDisplayInNewTabPage() const { | 337 bool Extension::ShouldDisplayInNewTabPage() const { |
338 // Only apps should be displayed on the NTP. | 338 // Only apps should be displayed on the NTP. |
339 return is_app() && display_in_new_tab_page_ && !is_ephemeral(); | 339 return is_app() && display_in_new_tab_page_; |
340 } | 340 } |
341 | 341 |
342 bool Extension::ShouldDisplayInExtensionSettings() const { | 342 bool Extension::ShouldDisplayInExtensionSettings() const { |
343 // Don't show for themes since the settings UI isn't really useful for them. | 343 // Don't show for themes since the settings UI isn't really useful for them. |
344 if (is_theme()) | 344 if (is_theme()) |
345 return false; | 345 return false; |
346 | 346 |
347 // Don't show component extensions and invisible apps. | 347 // Don't show component extensions and invisible apps. |
348 if (ShouldNotBeVisible()) | 348 if (ShouldNotBeVisible()) |
349 return false; | 349 return false; |
(...skipping 431 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
781 | 781 |
782 UpdatedExtensionPermissionsInfo::UpdatedExtensionPermissionsInfo( | 782 UpdatedExtensionPermissionsInfo::UpdatedExtensionPermissionsInfo( |
783 const Extension* extension, | 783 const Extension* extension, |
784 const PermissionSet* permissions, | 784 const PermissionSet* permissions, |
785 Reason reason) | 785 Reason reason) |
786 : reason(reason), | 786 : reason(reason), |
787 extension(extension), | 787 extension(extension), |
788 permissions(permissions) {} | 788 permissions(permissions) {} |
789 | 789 |
790 } // namespace extensions | 790 } // namespace extensions |
OLD | NEW |