-
Notifications
You must be signed in to change notification settings - Fork 113
Detecting Touch Devices
Srdjan Djenader edited this page Dec 21, 2017
·
2 revisions
detectTouch: function() {
// Your code goes here
}
- This function must return
true
orfalse
. - If the function returns
true
, DrawerJs assumes it runs on a touch device and will …- adjust its toolbar size (see property toolbarSizeTouch)
- adjust its context menu size
- use touch-optimized settings for object control (see property objectControlsTouch)
- add touch events
- If this function is not specified explicitly, DrawerJs will use its own touch detection mechanism.
To disable touch detection entirely, simply return false
from the detectTouch
function:
detectTouch: function() {
return false;
}
Getting Started
Plugins
-
Drawing Tools
-
Drawing Options
-
Advanced Configuration
Redactor Plugin Specific
DEMO