Added Secure Notes items to menu.
authorRyan C. Gordon <icculus@icculus.org>
Mon, 10 Feb 2014 20:11:43 -0500
changeset 25 44b6b8b34eb8
parent 24 c34cc914f09d
child 26 52d346bbaa51
Added Secure Notes items to menu.
1pass.lua
--- a/1pass.lua	Mon Feb 10 19:42:31 2014 -0500
+++ b/1pass.lua	Mon Feb 10 20:11:43 2014 -0500
@@ -14,6 +14,7 @@
     ["wallet.membership.Membership"] = "Memberships",
     ["wallet.government.DriversLicense"] = "Drivers licenses",
     ["system.Tombstone"] = "Dead items",
+    ["securenotes.SecureNote"] = "Secure notes",
     -- !!! FIXME: more!
 }
 
@@ -24,6 +25,7 @@
     "wallet.financial.BankAccountUS",
     "wallet.membership.Membership",
     "wallet.government.DriversLicense",
+    "securenotes.SecureNote",
     -- never show "system.Tombstone",
     -- !!! FIXME: more!
 }
@@ -219,6 +221,10 @@
 end
 secret_menuitem_builders["wallet.financial.CreditCard"] = build_secret_menuitem_creditcard
 
+local function build_secret_menuitem_securenote(menu, info, secure)
+    build_secret_menuitem(menu, "Notes", secure.notesPlain, true)
+end
+secret_menuitem_builders["securenotes.SecureNote"] = build_secret_menuitem_securenote
 
 local function build_secret_menuitems(info, menu)
     local metadata = load_json(basedir .. "/" .. info.uuid .. ".1password")