aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Alexis Degrugillier <github@ainw.org> 2014-04-07 19:07:01 -0400
committerGravatar Alexis Degrugillier <github@ainw.org> 2014-04-07 19:07:01 -0400
commit117396f75126ad966390c367bbdd8e9e17790d66 (patch)
treec03f27e650b74ec054a4359c36cc4de48a86e260
parent40df0eb4524546f4e0561b4b6548dffa4b987299 (diff)
Change click behavior on articles
Before, when the user click on an article it closes even if he want to select text. This behavior was not acceptable, so I changed it to close the article when cliking on the article footer or in the article margins. See #473
-rw-r--r--p/scripts/main.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/p/scripts/main.js b/p/scripts/main.js
index 03870da25..c3069b734 100644
--- a/p/scripts/main.js
+++ b/p/scripts/main.js
@@ -604,6 +604,9 @@ function init_shortcuts() {
function init_stream(divStream) {
divStream.on('click', '.flux_header,.flux_content', function (e) { //flux_toggle
+ if ($(e.target).parents('.content').length > 0) {
+ return;
+ }
if ($(e.target).closest('.item.website, .item.link').length > 0) {
return;
}