show autocomplete dbpedia box only with large screens : bug 0018336 V00.36
authorcavaliet
Mon, 09 Dec 2013 15:13:46 +0100
changeset 224 9b2367702bf0
parent 223 86efb26b3ba9
child 225 4d84d9e6cf37
show autocomplete dbpedia box only with large screens : bug 0018336
src/jocondelab/__init__.py
src/jocondelab/static/jocondelab/js/front-common.js
--- a/src/jocondelab/__init__.py	Mon Dec 09 12:47:42 2013 +0100
+++ b/src/jocondelab/__init__.py	Mon Dec 09 15:13:46 2013 +0100
@@ -1,4 +1,4 @@
-VERSION = (0, 35, 0, "final", 0)
+VERSION = (0, 36, 0, "final", 0)
 
 
 def get_version():
--- a/src/jocondelab/static/jocondelab/js/front-common.js	Mon Dec 09 12:47:42 2013 +0100
+++ b/src/jocondelab/static/jocondelab/js/front-common.js	Mon Dec 09 15:13:46 2013 +0100
@@ -53,8 +53,10 @@
             source: urls.ajax_terms,
             minLength: (lang === "ja" || lang == "zh") ? 1 : 2,
             focus: function(e, ui) {
-                showDbpediaBox(ui.item.dbpedia_uri);
-                setDbpediaBoxAnchor({type: "dom", selector: $(e.target).autocomplete("widget"), positioning: "side"});
+            	if(window.innerWidth>559){
+                    showDbpediaBox(ui.item.dbpedia_uri);
+                    setDbpediaBoxAnchor({type: "dom", selector: $(e.target).autocomplete("widget"), positioning: "side"});
+                }
             },
             response: function(e, ui) {
                 _(ui.content).each(function(c) {