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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/help/Help.js

Issue 2935393002: DevTools: stop whats new from opening on fresh profile (Closed)
Patch Set: tests Created 3 years, 6 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 | « third_party/WebKit/LayoutTests/inspector/help/release-note-unit-expected.txt ('k') | 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 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 /** 5 /**
6 * @return {!Help.ReleaseNote} 6 * @return {!Help.ReleaseNote}
7 */ 7 */
8 Help.latestReleaseNote = function() { 8 Help.latestReleaseNote = function() {
9 if (!Help._latestReleaseNote) { 9 if (!Help._latestReleaseNote) {
10 /** @type {!Help.ReleaseNote} */ 10 /** @type {!Help.ReleaseNote} */
(...skipping 15 matching lines...) Expand all
26 26
27 Help.showReleaseNoteIfNeeded = function() { 27 Help.showReleaseNoteIfNeeded = function() {
28 Help._showReleaseNoteIfNeeded(Help.releaseNoteVersionSetting().get(), Help.lat estReleaseNote().version); 28 Help._showReleaseNoteIfNeeded(Help.releaseNoteVersionSetting().get(), Help.lat estReleaseNote().version);
29 }; 29 };
30 30
31 /** 31 /**
32 * @param {number} lastSeenVersion 32 * @param {number} lastSeenVersion
33 * @param {number} latestVersion 33 * @param {number} latestVersion
34 */ 34 */
35 Help._showReleaseNoteIfNeeded = function(lastSeenVersion, latestVersion) { 35 Help._showReleaseNoteIfNeeded = function(lastSeenVersion, latestVersion) {
36 if (!lastSeenVersion) {
37 Help.releaseNoteVersionSetting().set(latestVersion);
38 return;
39 }
36 if (lastSeenVersion >= latestVersion) 40 if (lastSeenVersion >= latestVersion)
37 return; 41 return;
38 Help.releaseNoteVersionSetting().set(latestVersion); 42 Help.releaseNoteVersionSetting().set(latestVersion);
39 UI.viewManager.showView(Help._releaseNoteViewId, true); 43 UI.viewManager.showView(Help._releaseNoteViewId, true);
40 }; 44 };
41 45
42 /** 46 /**
43 * @const 47 * @const
44 * @type {string} 48 * @type {string}
45 */ 49 */
46 Help._releaseNoteViewId = 'release-note'; 50 Help._releaseNoteViewId = 'release-note';
47 51
48 /** @typedef {!{title: string, subtitle: string, link: string}} */ 52 /** @typedef {!{title: string, subtitle: string, link: string}} */
49 Help.ReleaseNoteHighlight; 53 Help.ReleaseNoteHighlight;
50 54
51 /** 55 /**
52 * @typedef {!{version: number, header: string, highlights: !Array<!Help.Release NoteHighlight>, 56 * @typedef {!{version: number, header: string, highlights: !Array<!Help.Release NoteHighlight>,
53 * link: string}} 57 * link: string}}
54 */ 58 */
55 Help.ReleaseNote; 59 Help.ReleaseNote;
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/inspector/help/release-note-unit-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698