Jump to content
AIDA64 Discussion Forum
Quozzo

RemoteSensor Fullscreen Suggestion

Recommended Posts

I'm using RemoteSensor on my tablet to view AIDA64 but due to the device's browser having an annoying nav bar which gets in the way, the screen doesn't exactly fit. Being able to maximise it with a button would be great, but then the button would be visible. So how about maximising on a double click? Here's the JavaScript for it.

 

	function requestFullScreen() {

		var requestMethod = document.body.requestFullScreen || document.body.webkitRequestFullScreen || document.body.mozRequestFullScreen || document.body.msRequestFullScreen;

		if (requestMethod) {
			requestMethod.call(document.body);
		} else if (typeof window.ActiveXObject !== "undefined") {
			var wscript = new ActiveXObject("WScript.Shell");
			if (wscript !== null) {
				wscript.SendKeys("{F11}");
			}
		}
		requestFullScreen();
	}

	window.ondblclick = requestFullScreen;

You also need to disable zooming on devices otherwise doubletap to maximise wont work.

<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0"/>

That won't effect desktops/laptops.

 

It could be added to the HTML only when an option under the RemoteSensor tab it selected so it won't conflict with anyone who might want to keep the current functionality.

 

---------------------------------------------------------------

 

Another suggestion would be to add links that are available in the RemoteSensor that can change the page back and forth.

My reasoning is that I like page 1 to be an overview of my system with page 2 being a detailed look at my CPU and page 3 being a detailed look at my graphics card. It's possible to change between pages with my G19 keyboard but I can't see how to do that in the website with RemoteSensor. 

I had a look at the network traffic (in Resource Monitor) and it appears to be quite efficient. There's no outgoing messages only incoming ajax (http) requests with the data which is drawn via JavaScript. I'm not sure how the website could communicate with AIDA64, maybe use a query string at the end of the URL so it would look something like

192.168.0.1:80?page=1

but getting AIDA64 to read that... I'll leave that in your capable hands :P

Share this post


Link to post
Share on other sites

We've done some experiments with the JS code you've provided, and it doesn't seem to work all that well with either Chrome or Safari. Disabling pinch-zoom and double-tap zoom makes it less usable and more quirky due to device width and actual pixel width resolution discrepancies.  Not to mention the sad fact that Safari under iOS refuses to enter full-screen mode :)  We need to brainstorm a bit more over this: it would be great if we could find an alternative way to request full-screen mode.

As for page switching: RemoteSensor only supports automatic page rotation.  What we usually recommend about similar requests is to simply choose a 2x preview width and/or 2x preview height, compared to the values you normally choose.  That way you can define 2 or 4 pages easily, either next to each other or on top of each other, and on your mobile device you can use swiping gestures to navigate to the page you wish to monitor.  BTW, this kind of usage scenario stops working if you need to fix the viewport parameters as per your request :( 

Share this post


Link to post
Share on other sites

What would you suggest would be the best way to allow fullscreen mode without impacting the user? It's possible to create a button that allows fullscreen mode which is then invisible when in fullscreen. 

 

CSS

		html:fullscreen .fullscreen {
			visibility: hidden;
		}
		html:-moz-full-screen .fullscreen{
			visibility: hidden;
		}
		html:-ms-fullscreen .fullscreen{
			visibility: hidden;
		}
		html:-webkit-full-screen .fullscreen{
			visibility: hidden;
		}

 

JavaScript

(function(){
	function requestFullScreen() {

		var requestMethod = document.documentElement.requestFullScreen || document.documentElement.webkitRequestFullScreen || document.documentElement.mozRequestFullScreen || document.documentElement.msRequestFullScreen;

		if (requestMethod) {
			requestMethod.call(document.documentElement);
		} else if (typeof window.ActiveXObject !== "undefined") {
			var wscript = new ActiveXObject("WScript.Shell");
			if (wscript !== null) {
				wscript.SendKeys("{F11}");
			}
		}
	}

	function fsButtons(){
		var els = document.querySelectorAll('.fullscreen');
		for(var i = 0, k = els.length; i<k; i++){
			els[i].addEventListener("click", function(e) {
				requestFullScreen();
			});
		};
	}

	window.addEventListener('load', fsButtons);
})();

 

HTML

<input class='fullscreen' type='button' value='Fullscreen'/>

 

Works for the most part, except in IE (why am I not surprised :wacko: ) I'll fix that if you want to take it further.

 

Oh also, swiping on my phone/tablet doesn't change pages. I think that is what you were suggesting anyways.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×