HTML5 Canvas - Hide Mouse

Community Beginner ,
Jun 12, 2021 Jun 12, 2021

Copy link to clipboard

Copied

Hi, 

i am working on a projekt that is going to run in a chromium kiosk.

I am trying to hide the mouse (arrow) without success.

 

Which is the best way to hide the mouse?

 

Thanks!

Pete

Views

271

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Beginner , Jun 13, 2021 Jun 13, 2021
Hi,i added the style tag cursor:none;in the html document. That solution worked for me!

Likes

Translate

Translate
Adobe Community Professional ,
Jun 12, 2021 Jun 12, 2021

Copy link to clipboard

Copied

Hi.

 

This should work:

canvas.style.cursor = "none";

 

Please let us know.

 

Regards,

JC

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jun 12, 2021 Jun 12, 2021

Copy link to clipboard

Copied

Hi and thank you JC,

do i ad it as global skript?

 

Regards,

Pete

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Community Professional ,
Jun 12, 2021 Jun 12, 2021

Copy link to clipboard

Copied

No, because the canvas global variable won't be defined yet.

 

Put the code in the first frame of the main timeline.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jun 12, 2021 Jun 12, 2021

Copy link to clipboard

Copied

It is not working.

 

I am running your code to aminate through the mousewheel.

 

 

 

var root = this;

root.targetTimeline = this;
root.targetTimeline.loop = true;
root.targetTimeline.force = 0.7; //war 1
root.targetTimeline.friction = 0.8;
root.targetTimeline.direction = -1; // scroll direction
root.targetTimeline.minFrame = 0; // set the start range value here
root.targetTimeline.maxFrame = root.targetTimeline.totalFrames - 1; // set the end range value here
root.targetTimeline.speed = 0;
root.targetTimeline.pressed = false;

 

 

If i add the line :

canvas.style.cursor = "none";

 Nothing is working anymore.

 

Thank you for your help!

Regards

Pete

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Community Professional ,
Jun 13, 2021 Jun 13, 2021

Copy link to clipboard

Copied

If it's for a kiosk, you may as well just hide the mouse cursor for the entire document.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jun 13, 2021 Jun 13, 2021

Copy link to clipboard

Copied

LATEST

Hi,

i added the style tag 

cursor:none;

in the html document.

 

That solution worked for me!

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines