Page 57 of 184

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 15:08
by Blueone
I found a little issue,

When I add this in the custom css in won't use it (changing the stand-by background color)

Code: Select all

.standby .fullslider {
	background-image:none !important;
	background-color:#000000 !important;
}
When I change it in the creative.css is does work, maybe a bug?

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 15:11
by crashingdutchman
robgeerts wrote:
crashingdutchman wrote:I wanted to use the mediaplayer next button twice to change to 2 stations up, but my clicks were noted as a double click and my iPad zoomed in on that part of the screen. Can you disable the registration of double clicks on buttons like these and handle them as 2 single clicks?

Also, the nu.nl frame (or popup) is still to big for my iPad Mini.
Edit: also valid for other popups like radio (nederland.fm) and my TV guide popups.
Will check out the popups.
Regarding the zoom-function, could you try adding this snippet to custom.js, right BEFORE:
function afterGetDevices(){

Code: Select all

(function($) {
  var IS_IOS = /iphone|ipad/i.test(navigator.userAgent);
  $.fn.nodoubletapzoom = function() {
    if (IS_IOS)
      $(this).bind('touchstart', function preventZoom(e) {
        var t2 = e.timeStamp
          , t1 = $(this).data('lastTouch') || t2
          , dt = t2 - t1
          , fingers = e.originalEvent.touches.length;
        $(this).data('lastTouch', t2);
        if (!dt || dt > 500 || fingers > 1) return; // not double-tap

        e.preventDefault(); // double tap - prevent the zoom
        // also synthesize click events we just swallowed up
        $(this).trigger('click').trigger('click');
      });
  };
})(jQuery);

If this works, I'll add it to the core scripts :)
Rob,

Thank you for your response!

That didn't work. I did some testing myself and found that changing the viewport to the following in index.html solved it:

Code: Select all

<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0"/>
I am not sure if this is recommended for other devices, most likely it isn't. However, you could maybe change it programmatically for just iOS devices, just as you are trying to catch the double-click event with your suggested code.

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 15:12
by robgeerts
Well, i found that fix too but they said it doesnt work for ios10...

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 15:16
by Blueone
I updated it to the last version but the following code isn't working for the raspberry with touchscreen:

Code: Select all

   if(!isMobile){
	$('body').bind('mousemove', function(e){
		standbyTime=0;
		disableStandby();
	});
   }
It doesn't go to standby with this code active.

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 15:24
by crashingdutchman
robgeerts wrote:Well, i found that fix too but they said it doesnt work for ios10...
It works for me, both on Chrome and Safari on an iPad Mini with the latest iOS 10(.3.2).

Edit: it also works in Chrome in my browser (Chrome on Windows 10)

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 16:46
by bierlaagh
Very happy with Dashticz V2.0 Thnx for that!

But now i encounter an issue wich i don't know if it is resolved or not (could not find it searching this topic)

I have a button and a Scene , Botch have IDX2

Code: Select all

blocks[2] = {}
blocks[2]['width'] = 4; 
blocks[2]['title'] = 'onkyo' 
blocks[2]['icon'] = 'fa-volume-up';
in Config.js i already renamed the Scene :

Code: Select all

blocks['s2'] = {}
blocks['s2']['type'] = 'Scene';
blocks['s2']['width'] = 12; 
blocks['s2']['title'] = 'Alles uit' 
blocks['s2']['icon'] = 'fa-power-off';
But still the scene has the same name as the power button and i haven't figured out why.
2017-04-18 16_15_55-Microsoft Edge.png
2017-04-18 16_15_55-Microsoft Edge.png (302.93 KiB) Viewed 2297 times
Hope someone can helpme getting back on the right track :)

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 17:03
by marcotrumpet
marcotrumpet wrote:Guys, just thinking..

Do you think it is possible to show (maybe with a buttons.panel) the domoticz security panel to insert allarm code?
Done simply adding a button with the url of the panel but it's too large on my phone.. I don't know how to resize


Inviato dal mio iPhone utilizzando Tapatalk

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 17:03
by marcotrumpet
marcotrumpet wrote:Guys, just thinking..

Do you think it is possible to show (maybe with a buttons.panel) the domoticz security panel to insert allarm code?
Done simply adding a button with the url of the panel but it's too large on my phone.. I don't know how to resize


Inviato dal mio iPhone utilizzando Tapatalk

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 17:40
by SwordFish
I'm sorry to say but since the last few updates i also noticed that the dashboard is responding slow. For example the clock isn't showing instantly and when its show its take a few seconds before its is on time. I've try to clear cache, reboot pi etc etc. On my tablet i looked this morning and just now its still said that it was 10.10u and within seconds its start to update the clock. I had this not with previous versions? Can it have anything to do with the way the rss feeds are working now for train, trafic etc? Just think out loud ;)

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 18:33
by madrian
SwordFish wrote:I'm sorry to say but since the last few updates i also noticed that the dashboard is responding slow. For example the clock isn't showing instantly and when its show its take a few seconds before its is on time. I've try to clear cache, reboot pi etc etc. On my tablet i looked this morning and just now its still said that it was 10.10u and within seconds its start to update the clock. I had this not with previous versions? Can it have anything to do with the way the rss feeds are working now for train, trafic etc? Just think out loud ;)
Check network tab in Developer Tools (Chrome/FF: right click Inspect then Network tab). For me it is around 2.5sec.

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 19:14
by SwordFish
madrian wrote:
SwordFish wrote:I'm sorry to say but since the last few updates i also noticed that the dashboard is responding slow. For example the clock isn't showing instantly and when its show its take a few seconds before its is on time. I've try to clear cache, reboot pi etc etc. On my tablet i looked this morning and just now its still said that it was 10.10u and within seconds its start to update the clock. I had this not with previous versions? Can it have anything to do with the way the rss feeds are working now for train, trafic etc? Just think out loud ;)
Check network tab in Developer Tools (Chrome/FF: right click Inspect then Network tab). For me it is around 2.5sec.
Somewhere around that, 2 to 4 seconds

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 19:28
by madrian
Robert,

For buttons.radar I have a gif file. But it's constantly reloading generating huge traffic.

buttons.radar = {icon: 'fa-cloud', title: 'Radar', url: 'http://192.168.1.54:8080/frontpage/idokep.gif?rand='+ Math.random()}

(math.random part is to prevent caching image).
Screen-Shot-2017-04-18-19-00-31.png
Screen-Shot-2017-04-18-19-00-31.png (237.37 KiB) Viewed 2258 times

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 19:29
by madrian
SwordFish wrote: Check network tab in Developer Tools (Chrome/FF: right click Inspect then Network tab). For me it is around 2.5sec.
Somewhere around that, 2 to 4 seconds
That's normal. For me in 2.54sec everything is showing instantly, but I am running domoticz on an Intel Atom platform.

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 19:50
by robgeerts
A quick post (not at home). The larger the dashboard gets, the larger response times etc. BUT i am going to speed uo things. Please stay tuned :)

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 19:53
by SwordFish
Thanks, looking forward to


Verzonden vanaf mijn iPhone met Tapatalk

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 22:20
by robgeerts
crashingdutchman wrote:
robgeerts wrote:Well, i found that fix too but they said it doesnt work for ios10...
It works for me, both on Chrome and Safari on an iPad Mini with the latest iOS 10(.3.2).

Edit: it also works in Chrome in my browser (Chrome on Windows 10)
Ok, added that fix to latest version. (Pushing tomorrow, I think, to gitlab!)


bierlaagh wrote:Very happy with Dashticz V2.0 Thnx for that!

But now i encounter an issue wich i don't know if it is resolved or not (could not find it searching this topic)

I have a button and a Scene , Botch have IDX2

Code: Select all

blocks[2] = {}
blocks[2]['width'] = 4; 
blocks[2]['title'] = 'onkyo' 
blocks[2]['icon'] = 'fa-volume-up';
in Config.js i already renamed the Scene :

Code: Select all

blocks['s2'] = {}
blocks['s2']['type'] = 'Scene';
blocks['s2']['width'] = 12; 
blocks['s2']['title'] = 'Alles uit' 
blocks['s2']['icon'] = 'fa-power-off';
Ok, fixed in latest version. (Pushing tomorrow, I think, to gitlab!)

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 23:20
by madrian
C'mon guys, no new post in the last hour? Is this project dead?

I don't think so, new Thermostat selector is submitted for review. :lol:



p.s: you won't belive how many hours needs a little modification like this (100 line of code). :shock:
p.s.2: I am not 100% satisfied with the CSS, it works, but If there is a CSS master he should check it. 8-)

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 23:23
by robgeerts
Looks nice, when can i implement this? (Good night for now)

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Tuesday 18 April 2017 23:24
by madrian
robgeerts wrote:Looks nice, when can i implement this? (Good night for now)
It's already merge requested, it's up to you. :)

Re: Dashticz v2.0, custom positioning and multiple screens

Posted: Wednesday 19 April 2017 12:29
by wizjos
Personally I don't like the wind-direction as Domoticz returns it... All english texts like 'ENE', 'WSW' etc.
Created a function to change this and give more descriptive texts like 'oost-noordoost' or 'west-zuidwest'.
To achieve this I hacked in to blocks.js...
Created a function TranslateDirection:

Code: Select all

function TranslateDirection(directionstr){
	directionstr='direction_'+directionstr;
	return lang[directionstr];
}
Altered the line:
blocktypes.Type['Wind'] = { icon: 'wi wi-wind-direction', title: lang.wind, value: '<Speed> m/s, <Direction> <DirectionStr>' }
in:

Code: Select all

blocktypes.Type['Wind'] = { icon: 'wi wi-wind-direction', title: lang.wind, value: '<Speed> m/s, <Direction>&deg; ' }
(with a degree sign as well)
and added an extra line (the third) in this piece of code:

Code: Select all

	if(typeof(device['Direction'])!=='undefined' && typeof(device['DirectionStr'])!=='undefined'){
		attr+=' style="-webkit-transform: rotate('+device['Direction']+'deg);-moz-transform: rotate('+device['Direction']+'deg);-ms-transform: rotate('+device['Direction']+'deg);-o-transform: rotate('+device['Direction']+'deg); transform: rotate('+device['Direction']+'deg);"';
		value = value+TranslateDirection(device['DirectionStr']);
	}
And finally added in the language file these lines

Code: Select all

lang['direction_N'] = 'noord'
lang['direction_NNE'] = 'noord-noordoost';
lang['direction_NE'] = 'noordoost'
lang['direction_ENE'] = 'oost-noordoost';
lang['direction_E'] = 'oost';
lang['direction_ESE'] = 'oost-zuidoost' ;
lang['direction_SE'] = 'zuidoost' ;
lang['direction_SSE'] = 'zuid-zuidoost' ;
lang['direction_S'] = 'zuid' ;
lang['direction_SSW'] = 'zuid-zuidwest' ;
lang['direction_SW'] = 'zuid-west' ;
lang['direction_WSW'] = 'west-zuidwest' ;
lang['direction_W'] = 'west' ;
lang['direction_WNW'] = 'west-noordwest' ;
lang['direction_NW'] = 'noordwest' ;
lang['direction_NNW'] = 'noord-noordwest' ;
All that remains now is a translation from m/s into Bft (Beaufort) :mrgreen:

Regards
Wizjos

EDIT: forgot some directions :oops: