From bfe24b7dfb955d582e551b2ef3635bc5c1c676ad Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Thu, 17 Apr 2014 01:29:44 -0300 Subject: [PATCH] popovers for icons in label icon chooser --- .../src/main/resources/messages_en.properties | 126 ++++++++++++++++++ wise-webapp/src/main/webapp/js/mindmapList.js | 14 +- 2 files changed, 139 insertions(+), 1 deletion(-) diff --git a/wise-webapp/src/main/resources/messages_en.properties b/wise-webapp/src/main/resources/messages_en.properties index 5f667902..0ce64939 100644 --- a/wise-webapp/src/main/resources/messages_en.properties +++ b/wise-webapp/src/main/resources/messages_en.properties @@ -282,6 +282,132 @@ OPEN_OFFICE_EXPORT_FORMAT_DETAILS=Get your map as OpenOffice Write Document MINDJET_EXPORT_FORMAT=(BETA) MindJet 8.x MINDJET_EXPORT_FORMAT_DETAILS=Export your maps in MindJet 8.x format MINDMAP_IS_LOCKED=Mindmap is locked for edition. +# icons.. +ASTERISK=Asterisk +PLUS=Plus +EURO=Euro +MINUS=Minus +CLOUD=Cloud +ENVELOPE=Envelope +PENCIL=Pencil +CLASS=Glass +MUSIC=Music +HEART=Heart +STAR=Star +STAR-EMPTY=Empty Star +USER=User +FILM=Film +OK=Ok +REMOVE=Remove +SIGNAL=Signal +COG=Cog +TRASH=Trash +FILE=File +TIME=Time +DOWNLOAD-ALT=Download +DOWNLOAD=Download +UPLOAD=Upload +INBOX=Inbox +REPEAT=Repeat +REFRESH=Refresh +LIST-ALT=List +LOCK=Lock +FLAG=Flag +HEADPHONES=Headphones +GRCODE=GR Code +BARCODE=Barcode +TAG=Tag +TAGS=Tags +BOOK=Book +BOOKMARK=Bookmark +PRING=Print +CAMERA=Camera +LIST=List +FACETIME-VIDEO=Facetime Video +PICTURE=Picture +MAP-MARKER=Map Maker +ADJUST=Adjust +TINT=Tint +EDIT=Edit +CHECK=Check +CHEVRON-LEFT=Chevron Left +CHEVRON-RIGHT=Chevron Right +PLUS-SIGN=Plus Sign +MINUS-SIGN=Minus Sign +REMOVE-SIGN=Remove Sign +OK-SIGN=Ok Sign +QUESTION-SIGN=Question Sign +INFO-SIGN=Info Sign +SCREENSHOT=Screenshot +REMOVE-CIRCLE=Remove Circle +OK-CIRCLE=Ok Circle +BAN-CIRCLE=Ban Circle +ARROW-LEFT=Arrow Left +ARROW-RIGHT=Arrow Right +ARROW-UP=Arrow Up +ARROW-DOWN=Arrow Down +SHARE-ALT=Share +EXCLAMATION-SIGN=Exclamation +GIFT=Gift +LEAF=Leaf +FIRE=Fire +EYE-OPEN=Open eye +EYE-CLOSE=Closed eye +WARNING-SIGN=Warning +PLANE=Plane +CALENDAR=Calendar +RANDOM=Random +COMMENT=Comment +MAGNET=Magnet +CHEVRON-UP=Chevrop Up +CHEVRON-DOWN=Chevron Down +SHOPPING-CART=Shopping +FOLDER-CLOSE=Closed Folder +FOLDER-OPEN=Open Folder +HDD=HDD +BULLHORN=Bullhorn +BELL=Bell +CERTIFICATE=Certificate +THUMBS-UP=Thumbs up +THUMBS-DOWN=Thumbs down +HAND-RIGHT=Hand right +HAND-LEFT=Hand left +HAND-UP=Hang up +HAND-DOWN=Hang down +CIRCLE-ARROW-RIGHT=Circle right +CIRCLE-ARROW-LEFT=Circle left +CIRCLE-ARROW-UP=Circle up +CIRCLE-ARROW-DOWN=Circle down +GLOBE=Globe +WRENCH=Wrench +TASKS=Tasks +FILTER=Filter +BRIEFCASE=Briefcase +PAPERCLIP=Paperclip +HEART-EMPTY=Empty Heart +LINK=Link +PHONE=Phone +PUSHPIN=Pushpin +USD=USD +GBP=GBP +UNCHECKED=Unchecked +FLASH=Flash +RECORD=Record +SAVED=Saved +SEND=Send +FLOPPY-DISK=Floppy Disk +TRANSFER +CUTLERY=Cutlery +HEADER=Header +COMPRESSED=Compressed +EARPHONE=Earphone +PHONE-ALT=Phone +TOWER=Tower +STATS=Stats +COPYRIGTH-MARK=Copyright +REGISTRATION-MARK=Registration Mark +CLOUD-DOWNLOAD=Cloud Download +CLOUD-UPLOAD=Cloud Updload diff --git a/wise-webapp/src/main/webapp/js/mindmapList.js b/wise-webapp/src/main/webapp/js/mindmapList.js index 5f4dd119..67addd10 100644 --- a/wise-webapp/src/main/webapp/js/mindmapList.js +++ b/wise-webapp/src/main/webapp/js/mindmapList.js @@ -539,7 +539,19 @@ $(function () { }); - $(".bs-glyphicons-list li").on("click", function(){ + //init popovers... + var icons = $(".bs-glyphicons-list li"); + icons.each(function() { + $(this).popover({ + animation: true, + placement: "auto", + trigger: 'hover', + //FIXME: Which is the best way to use messages.properties here? + content: ($(this).attr('class').replace('glyphicon glyphicon-','')) + }) + }); + + icons.on("click", function(){ var defaultIcon = $("#defaultIcon"); //remove current icon defaultIcon.find("i").remove();