From 7b15f27ba48f5a1b0e24290379e2524796776803 Mon Sep 17 00:00:00 2001 From: Simon L'nu Date: Fri, 16 Mar 2012 13:31:59 -0400 Subject: [PATCH 1/6] weee, dispys get another update Signed-off-by: Simon L'nu --- view/theme/dispy-dark/style.css | 51 ++-- view/theme/dispy-dark/theme.php | 8 +- view/theme/dispy/contact_template.tpl | 2 + view/theme/dispy/group_side.tpl | 6 +- view/theme/dispy/head.tpl | 19 -- view/theme/dispy/jot-header.tpl | 14 ++ view/theme/dispy/nav.tpl | 16 +- view/theme/dispy/nets.tpl | 2 +- view/theme/dispy/photo_view.tpl | 2 +- view/theme/dispy/profile_vcard.tpl | 30 ++- view/theme/dispy/saved_searches_aside.tpl | 2 +- view/theme/dispy/style.css | 282 +++++++++++++--------- view/theme/dispy/theme.php | 41 ++-- view/theme/dispy/wall_item.tpl | 5 +- view/theme/dispy/wallwall_item.tpl | 7 +- 15 files changed, 293 insertions(+), 194 deletions(-) mode change 100755 => 100644 view/theme/dispy/nets.tpl mode change 100755 => 100644 view/theme/dispy/photo_view.tpl mode change 100755 => 100644 view/theme/dispy/saved_searches_aside.tpl diff --git a/view/theme/dispy-dark/style.css b/view/theme/dispy-dark/style.css index d1ec4efd73..b4aefbbf23 100644 --- a/view/theme/dispy-dark/style.css +++ b/view/theme/dispy-dark/style.css @@ -123,9 +123,6 @@ a { text-decoration: none; margin-bottom: 1px; } -/*a:hover { */ -/* text-decoration: none;*/ -/*}*/ a:hover img { text-decoration: none; } @@ -778,6 +775,15 @@ aside #viewcontacts { #profile-jot-text_ifr { width:99.900002% !important; } +[id$="jot-text_ifr"] { + width: 99.900002% !important; + color: #2e2f2e; + background: #eec; +} +[id$="jot-text_ifr"] .mceContentBody { + color: #2e2f2e; + background: #eec; +} #profile-attach-wrapper, #profile-audio-wrapper, #profile-link-wrapper, @@ -1527,7 +1533,6 @@ div[id$="wrapper"] br { } .mail-list-subject { font-size: 1.2em; - font-weight: bold; } .mail-list-delete-wrapper { float: right; @@ -1751,23 +1756,23 @@ div[id$="wrapper"] br { margin: 30px 0px; } .profile-edit-side-div { - /*background: #111;*/ - /*border-radius: 5px 5px 0px 0px;*/ - /*margin: 0px 0px 0px 0px;*/ - /*width: 100px;*/ - /*height: 25px;*/ - /*position: absolute;*/ + /*background: #111; + border-radius: 5px 5px 0px 0px; + margin: 0px 0px 0px 0px; + width: 100px; + height: 25px; + position: absolute;*/ display: none; - /*left: 35%;*/ - /*top: 41%;*/ - /*cursor: pointer;*/ + /*left: 35%; + top: 41%; + cursor: pointer;*/ } -/*.profile-edit-side-div:hover {*/ - /*display: block;*/ -/*}*/ -/*.profile-edit-side-link {*/ - /*margin: 3px 0px 0px 70px;*/ -/*}*/ +/*.profile-edit-side-div:hover { + display: block; +} +.profile-edit-side-link { + margin: 3px 0px 0px 70px; +}*/ #profiles-menu-trigger { margin: 0px 0px 0px 25px; } @@ -2123,12 +2128,12 @@ div[id$="wrapper"] br { border-bottom: 1px solid #000; } #adminpage dt { - width: 200px; + width: 250px; float: left; font-weight: bold; } #adminpage dd { - margin-left: 200px; + margin-left: 250px; } #adminpage h3 { border-bottom:1px solid #ccc; @@ -2590,8 +2595,8 @@ footer { margin-top: 30px; overflow: auto; } -/*#acl-list-content {*/ -/*}*/ +/*#acl-list-content { +}*/ .acl-list-item { border: 1px solid #eec; display: block; diff --git a/view/theme/dispy-dark/theme.php b/view/theme/dispy-dark/theme.php index c0611ce83d..0134b1f91b 100644 --- a/view/theme/dispy-dark/theme.php +++ b/view/theme/dispy-dark/theme.php @@ -64,7 +64,7 @@ $(document).ready(function() { $('#drop-' + id).addClass('iconspacer'); } ); - // notifications + // click outside notifications menu closes it $('html').click(function() { $('#nav-notifications-linkmenu').removeClass('selected'); document.getElementById("nav-notifications-menu").style.display = "none"; @@ -74,6 +74,7 @@ $(document).ready(function() { event.stopPropagation(); }); + // main function in toolbar functioning function toggleToolbar() { if ( $('#nav-floater').is(':visible') ) { $('#nav-floater').slideUp('fast'); @@ -87,15 +88,20 @@ $(document).ready(function() { }); } }; + // our trigger for the toolbar button $('.floaterflip').click(function() { toggleToolbar(); return false; }); + // (attempt) to change the text colour in a top post $('#profile-jot-text').focusin(function() { $(this).css({color: '#eec'}); }); + // make auto-complete work in more places + $(".wall-item-comment-wrapper textarea").contact_autocomplete(baseurl+"/acl"); + /* $('#profile-photo-wrapper').mouseover(function() { $('.profile-edit-side-div').css({display: 'block'}); }).mouseout(function() { diff --git a/view/theme/dispy/contact_template.tpl b/view/theme/dispy/contact_template.tpl index fbf354b475..04968bd07d 100644 --- a/view/theme/dispy/contact_template.tpl +++ b/view/theme/dispy/contact_template.tpl @@ -20,9 +20,11 @@
$contact.name
+{{ if $contact.alt_text }}
$contact.alt_text
{{ endif }}
Profile URL
$contact.network
+ diff --git a/view/theme/dispy/group_side.tpl b/view/theme/dispy/group_side.tpl index 516d70d5b4..10ecec2e85 100644 --- a/view/theme/dispy/group_side.tpl +++ b/view/theme/dispy/group_side.tpl @@ -1,5 +1,5 @@ -
-

$title

+
+

$title

+
$item.name From 75823c23539fd009a6575dc125258afa7ce2bbc8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20H=C3=B6=C3=9Fl?= Date: Fri, 16 Mar 2012 17:45:07 +0000 Subject: [PATCH 2/6] Use tabindex to enable easy navigation in the dialog to write private mails; Recipient -> Subject -> Text field (tabindex has to be set to the IFRAME element after TinyMCE started) -> Send button --- include/acl_selectors.php | 14 ++++++++------ mod/message.php | 2 +- view/msg-header.tpl | 9 ++++++++- view/prv_message.tpl | 6 +++--- 4 files changed, 20 insertions(+), 11 deletions(-) diff --git a/include/acl_selectors.php b/include/acl_selectors.php index 67d8cebdeb..a5f5aff532 100755 --- a/include/acl_selectors.php +++ b/include/acl_selectors.php @@ -113,11 +113,13 @@ function contact_selector($selname, $selclass, $preselected = false, $options) { $str_nets = implode(',',$x['networks']); $sql_extra .= " AND `network` IN ( $str_nets ) "; } + + $tabindex = (x($options, 'tabindex') ? "tabindex=\"" . $options["tabindex"] . "\"" : ""); if($x['single']) - $o .= "\r\n"; else - $o .= "\r\n"; $r = q("SELECT `id`, `name`, `url`, `network` FROM `contact` WHERE `uid` = %d AND `self` = 0 AND `blocked` = 0 AND `pending` = 0 AND `notify` != '' @@ -156,7 +158,7 @@ function contact_selector($selname, $selclass, $preselected = false, $options) { -function contact_select($selname, $selclass, $preselected = false, $size = 4, $privmail = false, $celeb = false, $privatenet = false) { +function contact_select($selname, $selclass, $preselected = false, $size = 4, $privmail = false, $celeb = false, $privatenet = false, $tabindex = null) { $a = get_app(); @@ -178,12 +180,12 @@ function contact_select($selname, $selclass, $preselected = false, $size = 4, $p $sql_extra .= " AND `network` IN ( 'dfrn', 'mail', 'face', 'dspr' ) "; } - + $tabindex = ($tabindex > 0 ? "tabindex=\"$tabindex\"" : ""); if($privmail) - $o .= "\r\n"; else - $o .= "\r\n"; $r = q("SELECT `id`, `name`, `url`, `network` FROM `contact` WHERE `uid` = %d AND `self` = 0 AND `blocked` = 0 AND `pending` = 0 AND `notify` != '' diff --git a/mod/message.php b/mod/message.php index 55e313776d..0907abd77f 100755 --- a/mod/message.php +++ b/mod/message.php @@ -154,7 +154,7 @@ function message_content(&$a) { $preselect = (isset($a->argv[2])?array($a->argv[2]):false); - $select = contact_select('messageto','message-to-select', $preselect, 4, true); + $select = contact_select('messageto','message-to-select', $preselect, 4, true, false, false, 10); $tpl = get_markup_template('prv_message.tpl'); $o .= replace_macros($tpl,array( '$header' => t('Send Private Message'), diff --git a/view/msg-header.tpl b/view/msg-header.tpl index b5c78345a3..1f8650bfe3 100755 --- a/view/msg-header.tpl +++ b/view/msg-header.tpl @@ -30,8 +30,15 @@ if(plaintext != 'none') { setup : function(ed) { ed.onInit.add(function(ed) { ed.pasteAsPlainText = true; + var editorId = ed.editorId; + var textarea = $('#'+editorId); + console.log(textarea); + if (typeof(textarea.attr('tabindex')) != "undefined") { + $('#'+editorId+'_ifr').attr('tabindex', textarea.attr('tabindex')); + textarea.attr('tabindex', null); + } }); - } + }, }); } diff --git a/view/prv_message.tpl b/view/prv_message.tpl index 4b904cbcd6..2ce07ce6fd 100755 --- a/view/prv_message.tpl +++ b/view/prv_message.tpl @@ -10,14 +10,14 @@ $parent $select
$subject
- +
$yourmessage
- +
- +
From 27054964feba44e82589fb6b8c464c59b9420feb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20H=C3=B6=C3=9Fl?= Date: Fri, 16 Mar 2012 17:46:26 +0000 Subject: [PATCH 3/6] Forgot to remove a debug line --- view/msg-header.tpl | 1 - 1 file changed, 1 deletion(-) diff --git a/view/msg-header.tpl b/view/msg-header.tpl index 1f8650bfe3..b1fcefd247 100755 --- a/view/msg-header.tpl +++ b/view/msg-header.tpl @@ -32,7 +32,6 @@ if(plaintext != 'none') { ed.pasteAsPlainText = true; var editorId = ed.editorId; var textarea = $('#'+editorId); - console.log(textarea); if (typeof(textarea.attr('tabindex')) != "undefined") { $('#'+editorId+'_ifr').attr('tabindex', textarea.attr('tabindex')); textarea.attr('tabindex', null); From 90bb32ab7393687d46e198f94d181c830f881def Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20H=C3=B6=C3=9Fl?= Date: Fri, 16 Mar 2012 17:47:40 +0000 Subject: [PATCH 4/6] Bugfix of old IEs --- view/msg-header.tpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/view/msg-header.tpl b/view/msg-header.tpl index b1fcefd247..098333893f 100755 --- a/view/msg-header.tpl +++ b/view/msg-header.tpl @@ -37,7 +37,7 @@ if(plaintext != 'none') { textarea.attr('tabindex', null); } }); - }, + } }); } From 01f87108324eb6b45f3649400557ada4e54502f7 Mon Sep 17 00:00:00 2001 From: Simon L'nu Date: Fri, 16 Mar 2012 16:41:19 -0400 Subject: [PATCH 5/6] Merge branch 'master', remote-tracking branch 'remotes/upstream/master' * remotes/upstream/master: Bugfix of old IEs Forgot to remove a debug line Use tabindex to enable easy navigation in the dialog to write private mails; Recipient -> Subject -> Text field (tabindex has to be set to the IFRAME element after TinyMCE started) -> Send button * master: From 91fee866b7f870b66d770c7c4e6db0afd874de33 Mon Sep 17 00:00:00 2001 From: Simon L'nu Date: Fri, 16 Mar 2012 16:43:34 -0400 Subject: [PATCH 6/6] make profiles-menu disappear when clicked outside it Signed-off-by: Simon L'nu --- view/theme/dispy-dark/theme.php | 9 +++++++++ view/theme/dispy/theme.php | 9 +++++++++ 2 files changed, 18 insertions(+) diff --git a/view/theme/dispy-dark/theme.php b/view/theme/dispy-dark/theme.php index 0134b1f91b..b57971db96 100644 --- a/view/theme/dispy-dark/theme.php +++ b/view/theme/dispy-dark/theme.php @@ -73,6 +73,15 @@ $(document).ready(function() { $('#nav-notifications-linkmenu').click(function(event) { event.stopPropagation(); }); + // click outside profiles menu closes it + $('html').click(function() { + $('#profiles-menu-trigger').removeClass('selected'); + document.getElementById("profiles-menu").style.display = "none"; + }); + + $('#profiles-menu').click(function(event) { + event.stopPropagation(); + }); // main function in toolbar functioning function toggleToolbar() { diff --git a/view/theme/dispy/theme.php b/view/theme/dispy/theme.php index ac97948a38..9f0fcba828 100644 --- a/view/theme/dispy/theme.php +++ b/view/theme/dispy/theme.php @@ -73,6 +73,15 @@ $(document).ready(function() { $('#nav-notifications-linkmenu').click(function(event) { event.stopPropagation(); }); + // click outside profiles menu closes it + $('html').click(function() { + $('#profiles-menu-trigger').removeClass('selected'); + document.getElementById("profiles-menu").style.display = "none"; + }); + + $('#profiles-menu').click(function(event) { + event.stopPropagation(); + }); // main function in toolbar functioning function toggleToolbar() {