Gibt es eine Möglichkeit das Klick-Verhalten in der Visu zu ändern? Derzeit wird Beim Klick (Steigendeflanke) eine Aktion ausgelöst wie ansonsten üblich beim Loslassen!?
Ankündigung
Einklappen
Keine Ankündigung bisher.
Visu Klickverhalten
Einklappen
X
-
Nein, aber ich habe dies schon länger uff Liste stehen - also eine Frage der ZeitEDOMI - Intelligente Steuerung und Visualisierung KNX-basierter Elektro-Installationen (http://www.edomi.de)
-
+1
Da würde ich mich dem Wunsch anschließen. Irgendwie vermisse ich auch, dass man den langen Klick genauer definieren kann. Also 500ms oder 2s einstellen zu können wäre manchmal sehr praktisch.
Besonders Aktionen, die man nicht versehentlich auslösen will, könnte man so gezielt mit (deutlich) längerer Klickzeit belegen.
Kommentar
-
Zitat von vento66 Beitrag anzeigenDa wäre die Unterscheidung zwischen Drücken und Loslassen schon sinvoll, den Rest macht dann eine Logik.Viele Grüße, Vitali
Kommentar
-
So einfach ist das aber (im Nachhinein) nicht - irgendwie müssen ja auch die entsprechenden Befehle beim Loslassen/etc. definiert werden.
Zudem habe ich nie verstanden, warum man in einer Visu krampfhaft versucht einen echten Taster nachzubilden (also kurz/lang Unterscheidung) - schließlich ist doch Platz genug. Das Speichern von Szenen z.B. mache ich doch lieber auf einer entsprechenden Visuseite (quasi "System/Einstellungen") - dann überschreibt man Szenenwerte auch nicht versehentlich.EDOMI - Intelligente Steuerung und Visualisierung KNX-basierter Elektro-Installationen (http://www.edomi.de)
- Likes 1
Kommentar
-
Dem muss ich ein bisschen widersprechen. Es geht nicht darum einen normalen Taster nachzubilden (habe ich auch im Gebäude keine). Gerade bei einer mobilen Visu ist der Platz überschaubar*, und die Gefahr, dass man ungewollt eine Aktion auslöst doch recht hoch. Auch auf einer separaten "Einstellungen"-Seite würde ich es bevorzugen nicht versehentlich irgendwelche Einstellungen zu tätigen, nur weil der Daumen mal wieder zu dick war.
"Schatz,... ich glaube ich hab' aus Versehen die Stalltür in der Visu geöffnet, jetzt ist das Federvieh leider dem Fuchs zum Opfer gefallen..."
Wenn ich aber sicher sein kann, dass bestimmte Schaltflächen z.B. mindestens 1,5 Sekunden brauchen um etwas zu "verstellen", dann ist das entspannter.
*da ich gerade dabei bin eine mobile Visu fürs Smatphone zu bauen kann ich das etwas einschätzen. Allein eine vernünftige Navigation ist eine Herausforderung. Was dann noch vom Bildschirm bleibt ist nicht die Welt. Außerdem soll es ja kein 1990-Maschinen-Steuerung-Look werden sondern auch einigermaßen ansehnlich (WAF). Da sind vollgestopfte Visuseiten nicht so angebracht...
Kommentar
-
Auch wenn das etwas am Thema vorbei geht.. aber als "Schutz" vor ungewollter Betätigung nutze ich ein Popup... Sprich, man drückt auf einen Knopf, zb.
Garagentor AUF/ZU.. dann öffnet sich wie man das von Windows kennt ein Popup und frägt mich ob ich das wirklich will.. hier gibt es JA und NEIN..
und schon ist das gesichert... geht trotzdem super schnell zu bedienen und ist sicher sogar intuitiver wie "1,5 sek drücken das was passiert".. das
erklär mal der Frau, das sie da jetzt länger drücken muss um den Fuchs in den Hühnerstall zu lassen
Gruß Martin
Die Selbsthilfegruppe "UTF-8-Probleme" trifft sich diesmal abweichend im groüen Saal.
Kommentar
-
Zitat von Brick Beitrag anzeigenGaragentor AUF/ZU.. dann öffnet sich wie man das von Windows kennt ein Popup und frägt mich ob ich das wirklich will.. hier gibt es JA und NEIN..
Reicht schon wenn man im Arbeitsalltag davon genervt wird...
Kommentar
-
Zitat von mfd Beitrag anzeigen
Windows in der Visu nachahmen - soweit kommt's noch.
Reicht schon wenn man im Arbeitsalltag davon genervt wird...
Die Selbsthilfegruppe "UTF-8-Probleme" trifft sich diesmal abweichend im groüen Saal.
Kommentar
-
Der lange Klick ist doch gerade zum Schutz gedacht... Wo ist also das Problem?!EDOMI - Intelligente Steuerung und Visualisierung KNX-basierter Elektro-Installationen (http://www.edomi.de)
Kommentar
-
beides ist gut und schützt.
Allerdings ist der lange Klick eine "Geheiminfo" für jemanden, der Deine Visu nicht kennt. Wohlmöglich sieht er auch gar nicht den grünen Kreis-Fortschritt unter seinem Finger. Ein PopUp infomiert und hat auch keinen Zeitdruck bei der Funktion. Meine seniorige Mutter würde daher immer eine PopUp bevorzugen, weil man da nicht zu einer "zeitkritischen" Willenserklärung "gezwungen" wird ("da jetzt 2s drauf drücken"). Ein anderer bevorzugt eben den langen Druck, weil direkt das tut, was man möchte (wenn man es denn kennt).
Vielleicht wäre der "lange Klick" für manchen besser erkennbar, wenn der Fortschrittskreis in wählbarer Größe erscheinen könnte (ich würde ihn wohl erheblich größer wählen um es sichtbar zu machen für den Anwender) und vielleicht sogar währenddessen (also während der Wartezeit) ein (selbst gewählter) Info-Text als Tool-Tipp/Standard-Info-PopUp oder so etwas ausgegeben werden könnte. Das wäre dann ein recht probater Ersatz für ein PopUp und spart eben genau die selbst erstellte PopUp-Seite. Dazu noch die wählbare Drück-Zeit. Das wäre perfekt.
Ich persönlich nutze beides in unterschiedlichen Situationen. Aber mit den drei genannten Änderungen würde ich vermutlich künftig auf PopUps ganz verzichten.
Just my 2 cents
Kommentar
-
Ich hol das jetzt nochmal hoch, da ich seit dem Post damals bisher jede Version gepatcht habe.
Mittlerweile wird das automatisch per Script gepatcht.
Ergebnis ist ein "normales" Klickverhalten. Man kann also auch zoomen (falls notwendig) ohne Befehle auszulösen.
https://knx-user-forum.de/forum/projektforen/edomi/897500-edomi-fragen-zur-visuseitenerstellung?p=974401#post974401
das zusammengestückelte PHP Script sieht so aus:
PHP-Code:<?php
$timestamp = date('Y-m-d_H:i:s');
//$edomi_path = '/tmp/visu';
$edomi_path = '/usr/local/edomi/www/visu';
$source_path = '/usr/local/edomi/www/visu/';
$backup_path = "/var/edomi-modbackup/$timestamp";
// Logging class initialization
$log = new Logging();
// set path and name of log file (optional)
$log->lfile('/usr/local/edomi/www/data/log/CUSTOMLOG_ClickMod.log');
// write message to the log file
$log->lwrite("Backup Files to: $backup_path");
// make backup
rcopy ($source_path,$backup_path);
//********************************************************************************************************************************
$path_to_file = "$edomi_path/apps/app0.php";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent='touchstart';
moveEvent='touchmove';
upEvent='touchend';","downEvent='touchstart';
moveEvent='touchmove';
upEvent='touchend';
clickEvent='click';",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//********************************************************************************************************************************
$path_to_file = "$edomi_path/apps/app0.php";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent='mousedown';
moveEvent='mousemove';
upEvent='mouseup';
}","downEvent='mousedown';
moveEvent='mousemove';
upEvent='mouseup';
clickEvent='mousedown';
}",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//********************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control1.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//********************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control10.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//********************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control12.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace(".addEventListener(downEvent,function(){if (!checkClick()){return;} control12_Switch(item.id,0);},false);",".addEventListener(clickEvent,function(){if (!checkClick()){return;} control12_Switch(item.id,0);},false);",$file_contents,$i);
$file_contents = str_replace(".addEventListener(downEvent,function(){if (!checkClick()){return;} control12_Switch(item.id,1);},false);",".addEventListener(clickEvent,function(){if (!checkClick()){return;} control12_Switch(item.id,1);},false);",$file_contents,$j);
echo "Replacements: $i+$j in $path_to_file\n";
$log->lwrite("Replacements: $i+$j in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//********************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control14.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//********************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control17.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//*Kamerabild**********************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control20.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//*Diagramm************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control21.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//*Zeitschaltuhr************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control22.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//*Anwesenheitssimulation************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control23.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//*Codeschloss************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control24.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//*Meldungsarchiv************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control25.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//*Datenarchiv************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control26.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//*Rundinstrument************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control27.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//*Anrufarchiv************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control28.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//*Webseitenurl************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control29.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
//*Terminschaltuhr************************************************************************************************************************
$path_to_file = "$edomi_path/include/js/control32.js";
$file_contents = file_get_contents($path_to_file);
$file_contents = str_replace("downEvent","clickEvent",$file_contents,$i);
echo "Replacements: $i in $path_to_file\n";
$log->lwrite("Replacements: $i in $path_to_file");
file_put_contents($path_to_file,$file_contents);
// close log file
$log->lclose();
/**
* Recursively copy files from one directory to another
*
* @param String $src - Source of files being moved
* @param String $dest - Destination of files being moved
*/
function rcopy($src, $dest){
// If source is not a directory stop processing
if(!is_dir($src)) return false;
// If the destination directory does not exist create it
if(!is_dir($dest)) {
echo "$dest is no directory\n";
//$log->lwrite("$dest is no directory");
if(!mkdir($dest)) {
echo "could not create $dest\n";
//$log->lwrite("could not create $dest");
// If the destination directory could not be created stop processing
return false;
}
}
// Open the source directory to read in files
$i = new DirectoryIterator($src);
foreach($i as $f) {
if($f->isFile()) {
echo "copy $f to $dest\n";
//$log->lwrite("copy $f to $dest");
copy($f->getRealPath(), "$dest/" . $f->getFilename());
} else if(!$f->isDot() && $f->isDir()) {
rcopy($f->getRealPath(), "$dest/$f");
}
}
}
/**
* Logging class:
* - contains lfile, lwrite and lclose public methods
* - lfile sets path and name of log file
* - lwrite writes message to the log file (and implicitly opens log file)
* - lclose closes log file
* - first call of lwrite method will open log file implicitly
* - message is written with the following format: [d/M/Y:H:i:s] (script name) message
*/
class Logging {
// declare log file and file pointer as private properties
private $log_file, $fp;
// set log file (path and name)
public function lfile($path) {
$this->log_file = $path;
}
// write message to the log file
public function lwrite($message) {
// if file pointer doesn't exist, then open log file
if (!is_resource($this->fp)) {
$this->lopen();
}
// define script name
$script_name = pathinfo($_SERVER['PHP_SELF'], PATHINFO_FILENAME);
// define current time and suppress E_WARNING if using the system TZ settings
// (don't forget to set the INI setting date.timezone)
$time = @date('[d/M/Y:H:i:s]');
// write current time, script name and message to the log file
fwrite($this->fp, "$time ($script_name) $message" . PHP_EOL);
}
// close log file (it's always a good idea to close a file when you're done with it)
public function lclose() {
fclose($this->fp);
}
// open log file (private method)
private function lopen() {
// in case of Windows set default log file
if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') {
$log_file_default = 'c:/php/logfile.txt';
}
// set default log file for Linux and other systems
else {
$log_file_default = '/tmp/logfile.txt';
}
// define log file from lfile method or use previously set default
$lfile = $this->log_file ? $this->log_file : $log_file_default;
// open log file for writing only and place file pointer at the end of the file
// (if the file does not exist, try to create it)
$this->fp = fopen($lfile, 'a') or exit("Can't open $lfile!");
}
}
?>
Kommentar
Kommentar