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

Unified Diff: chrome/browser/resources/pdf/elements/viewer-bookmark/viewer-bookmark.js

Issue 865033002: Implement a slide-in pane for bookmarks. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@pdf-pane
Patch Set: Add checks when setting attributes on bookmarksPane Created 5 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/pdf/elements/viewer-bookmark/viewer-bookmark.js
diff --git a/chrome/browser/resources/pdf/elements/viewer-bookmark/viewer-bookmark.js b/chrome/browser/resources/pdf/elements/viewer-bookmark/viewer-bookmark.js
new file mode 100644
index 0000000000000000000000000000000000000000..a2ca92b4cec4c5a14fd8c840d75c3b8b7bed014b
--- /dev/null
+++ b/chrome/browser/resources/pdf/elements/viewer-bookmark/viewer-bookmark.js
@@ -0,0 +1,21 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+Polymer('viewer-bookmark', {
+
+ /**
+ * @type {Object}
+ * A bookmark object, each containing a:
+ * - title
+ * - page (optional)
+ * - children (an array of bookmarks)
+ */
+ bookmark: null,
+
+ onClick: function() {
+ if (this.bookmark.hasOwnProperty('page'))
+ this.fire('changePage', {page: this.bookmark.page});
+ },
+
+});

Powered by Google App Engine
This is Rietveld 408576698