diff --git a/lib/jquery.imgareaselect-1.0.0-rc1.min.js b/ext/notes/lib/jquery.imgareaselect-1.0.0-rc1.min.js similarity index 100% rename from lib/jquery.imgareaselect-1.0.0-rc1.min.js rename to ext/notes/lib/jquery.imgareaselect-1.0.0-rc1.min.js diff --git a/lib/jquery.imgnotes-1.0.min.css b/ext/notes/lib/jquery.imgnotes-1.0.min.css similarity index 100% rename from lib/jquery.imgnotes-1.0.min.css rename to ext/notes/lib/jquery.imgnotes-1.0.min.css diff --git a/lib/jquery.imgnotes-1.0.min.js b/ext/notes/lib/jquery.imgnotes-1.0.min.js similarity index 100% rename from lib/jquery.imgnotes-1.0.min.js rename to ext/notes/lib/jquery.imgnotes-1.0.min.js diff --git a/lib/spacer.gif b/ext/notes/lib/spacer.gif similarity index 100% rename from lib/spacer.gif rename to ext/notes/lib/spacer.gif diff --git a/ext/notes/script.js b/ext/notes/script.js index 6a90f0f7..c8726e24 100644 --- a/ext/notes/script.js +++ b/ext/notes/script.js @@ -4,6 +4,9 @@ $(function() { if(window.notes) { $('#main_image').load(function(){ $('#main_image').imgNotes({notes: window.notes}); + + //Make sure notes are always shown + $('#main_image').off('mouseenter mouseleave'); }); } diff --git a/ext/notes/style.css b/ext/notes/style.css index 111d8971..c4b00f4f 100644 --- a/ext/notes/style.css +++ b/ext/notes/style.css @@ -1,7 +1,8 @@ .note { - display: none; - background-color: #fffdef; - border: #412a21 1px solid; + display: block; + + background-color: #FFE; + border: 1px dashed black; overflow: hidden; position: absolute; z-index: 0; @@ -74,4 +75,13 @@ } .imgareaselect-selection { -} \ No newline at end of file +} + +/* Makes sure the note block is hidden */ +section#note_system { + height: 0; +} +section#note_system > .blockbody { + padding: 0; + border: 0; +} diff --git a/ext/notes/theme.php b/ext/notes/theme.php index 4d792901..ec8d7f35 100644 --- a/ext/notes/theme.php +++ b/ext/notes/theme.php @@ -44,6 +44,12 @@ class NotesTheme extends Themelet { // check action POST on form public function display_note_system(Page $page, $image_id, $recovered_notes, $adminOptions) { + $base_href = get_base_href(); + + $page->add_html_header(""); + $page->add_html_header(""); + $page->add_html_header(""); + $to_json = array(); foreach($recovered_notes as $note) { $parsedNote = $note["note"]; @@ -121,7 +127,7 @@ class NotesTheme extends Themelet { $html .= ""; - $page->add_block(new Block(null, $html, "main", 1)); + $page->add_block(new Block(null, $html, "main", 1, 'note_system')); }