Refer to additional API capabilities in the readme

This commit is contained in:
Manuel Vögele
2021-02-21 12:41:12 +01:00
parent bb5fe94439
commit 0fb8aecfdd
2 changed files with 15 additions and 10 deletions
+12 -10
View File
@@ -56,6 +56,18 @@ export class SpeedProvider {
return 0xFF0000
}
/**
* Returns a boolean indicating whether this token will use a Ruler or not.
* If this is returns `false` for a token Drag Ruler will be disabled for that token. Dragging a token for which this function
* returns false will behave as if Drag Ruler wasn't installed.
* If usesRuler returns `false` it's guranteed that the `getRanges` function won't be called for that token.
*
* Implementing this method is optional and only needs to be done if you want to disable Drag Ruler for some tokens.
*/
usesRuler(token) {
return true
}
/**
* Returns the value that is currently set for the setting registered with the provided settingId.
*
@@ -73,16 +85,6 @@ export class SpeedProvider {
}
}
/**
* Returns a boolean indicating whether this token will use a Ruler or not.
* If this is returns `false` for a token Drag Ruler will be disabled for that token. Dragging a token for which this function
* returns false will behave as if Drag Ruler wasn't installed.
* If usesRuler returns `false` it's guranteed that the `getRanges` function won't be called for that token.
*/
usesRuler(token) {
return true
}
/**
* Constructs a new instance of he speed provider
*