1
0
mirror of https://github.com/psychopy/psychojs.git synced 2025-05-10 10:40:54 +00:00
Commit Graph

844 Commits

Author SHA1 Message Date
Alain Pitiot
e3f8e7593c
Merge pull request #119 from thewhodidthis/bf#115--gui
core/GUI: swap placement of OK/Cancel dialog box buttons
2020-07-31 16:23:34 +02:00
Alain Pitiot
58947e5fa4
Merge pull request #122 from thewhodidthis/nf#121--randint
util/Util: add NumPy inspired randint method
2020-07-31 16:22:37 +02:00
Alain Pitiot
770d02d156
Merge branch 'master' into nf#121--randint 2020-07-31 16:22:25 +02:00
Alain Pitiot
8bb4753d20
Merge pull request #107 from peircej/master
BF: allow UK English names for colours. Any others?
2020-07-31 16:17:45 +02:00
Alain Pitiot
a447a495e5
Merge pull request #129 from thewhodidthis/nf#128--math
util/Util: add Crib Sheet math extras
2020-07-31 16:16:29 +02:00
Alain Pitiot
394311e650
Merge pull request #112 from thewhodidthis/nf#111--release
core/MinimalStim: add release method
2020-07-31 16:13:21 +02:00
Sotiri Bakagiannis
2088cf75c7 util/Util: add sum helper 2020-07-30 14:57:55 +01:00
Sotiri Bakagiannis
9308989117 util/Util: add round helper 2020-07-30 14:55:28 +01:00
Sotiri Bakagiannis
2fd6c30ddf data/ExperimentHandler: drop duplicate isEntryEmpty method 2020-07-29 09:36:26 +01:00
Sotiri Bakagiannis
7fd83d2ead util/Util: fix randint error message 2020-07-28 21:37:24 +01:00
Sotiri Bakagiannis
97542f794a util/Util: line separate the just added function opening brace 2020-07-28 15:18:17 +01:00
Sotiri Bakagiannis
7688f8df92 util/Util: add randint helper 2020-07-28 15:02:32 +01:00
Sotiri Bakagiannis
f4b9717467 core/GUI: swap placement of OK/Cancel dialog box buttons 2020-07-27 12:14:47 +01:00
Sotiri Bakagiannis
5b69621ffa core/MinimalStim: add release method 2020-07-24 17:11:40 +01:00
Sotiri Bakagiannis
e0b7bc8d5b visual/Image/Text/Movie/Shape: call destroy on internal pixi instance before updating across stimulus classes 2020-07-24 17:00:37 +01:00
Sotiri Bakagiannis
30755dbcb2 data/util: add missing semicolons 2020-07-24 15:28:59 +01:00
Sotiri Bakagiannis
cae18a0a3b data/TrialHandler: look for arrays in square brackets when importing conditions 2020-07-24 09:51:05 +01:00
Sotiri Bakagiannis
2a6138e4da util/Util: add turnSquareBracketsIntoArrays helper 2020-07-24 09:51:00 +01:00
Sotiri Bakagiannis
43dedcb7f7 core/Mouse: clean up JSDoc 2020-07-17 16:46:36 +01:00
Sotiri Bakagiannis
2909dabf83 core/Mouse: clean up mostly JSDoc 2020-07-17 15:06:58 +01:00
Sotiri Bakagiannis
460ba1998d core/Mouse: clean up comments 2020-07-17 12:30:15 +01:00
Sotiri Bakagiannis
d023ed3b8c core/Mouse: tweak isPressedIn to cover all types of arguments
Bring in line with PsychoPy by accepting arguments as follows:
(a) mouse.isPressedIn({"shape": myStim, "buttons": 1})
(b) mouse.isPressedIn(myStim, {"buttons": 1})
(c) mouse.isPressedIn(myStim, 1)
2020-07-16 17:21:04 +01:00
Jon Peirce
d3a71cd18d BF: allow UK English names for colours. Any others? 2020-07-16 16:50:28 +01:00
Sotiri Bakagiannis
e37eb5270a core/Mouse: add isPressedIn method 2020-07-14 12:57:20 +01:00
Sotiri Bakagiannis
e72da164ea css: center root pseudo message using tranform/translate
Should work unprefixed down to IE11.
2020-07-07 11:08:07 +01:00
Sotiri Bakagiannis
f12ccafff3 visual/VisualStim: flip rotations to reflect psychopy convention
The documentation for `setOri()` on `VisualStim` now
accurately reflects the mapping of negative values to
counter-clockwise rotations and vice versa.
2020-07-07 10:52:06 +01:00
Alain Pitiot
08972dae90
Merge pull request #99 from thewhodidthis/bf#53+83--slider
visual/Slider: override refresh method a-la ShapeStim
2020-07-03 14:38:41 +02:00
Alain Pitiot
1fc76d1461 complete linting, saving of partial results, improved GUI, various bug fixes 2020-07-03 14:26:43 +02:00
Sotiri Bakagiannis
2ba835f5c2 visual/Slider: override refresh method a-la ShapeStim
Insert a `refresh()` method into the `Slider` component to
switch on the `_needVertexUpdate` property so that resizing
the `Window` properly reflects on instance position.
2020-07-03 11:45:12 +01:00
Sijia Zhao
3ee07c994c BF: Remove <form>...</form> elements
Leaving the elements means that a user can press enter to submit the form. Since there is no action="..." attribute, will default to submitting the form to the current page, effectively causing a page reload. Because the intention is for the user to proceed by pressing the 'Ok' button on the jQuery dialog, this only causes an annoyance to the user.
2020-05-27 22:08:14 +01:00
Alain Pitiot
8276bd790a replace jquery escapeSelector by CSS.escape since the latter is standard and the former is only available in jquery 3.0 2020-05-24 14:23:00 +02:00
Alain Pitiot
c48af52eec
Merge pull request #90 from sijiazhao/master
BF: Multiple fixes, mostly re GUI dlg; fixes #52
2020-05-24 14:07:25 +02:00
Alain Pitiot
f688b65cd0
Merge branch 'master' into master 2020-05-24 14:03:00 +02:00
Alain Pitiot
934484e054 cancel a recent change to slider which seems to be creating issues; take devicePixelRatio into account in Windows 2020-05-24 13:45:32 +02:00
Sijia Zhao
584d76a04f Dialogs now properly destroyed and removed from DOM when closed
Ensures dialogs are immediately removed from DOM when closed.
Previously, dialogs were destroyed but not removed causing possibility of duplicate element IDs, so jQuery unitentionally selects and recreates old dialogs, thus  GUI._updateOkButtonStatus updates the wrong button.
2020-05-19 19:31:29 +01:00
Sijia Zhao
88827706ea ServerManager.downloadResources, ._downloadRegisteredResources: only process and download new resources, ignore existing resources
Old behaviour of ._downloadRegisteredResources attempts to download all registered resources, regardless of whether they have been previously downloaded. howler.js appears to ignore requests to re-download, however PreloadJS will redownload, which can cause critical errors if a resource is being used while being unnecessarily redownloaded
2020-05-19 19:22:19 +01:00
Sijia Zhao
0f9eeb636e GUI._onKeyChange now properly handles dropdown boxes
Now use a Map to keep track of individual elements to prevent duplication.
Previously would increment continuously just by switching dropdown options. So users could bypass the requirement to complete starred(*) fields by toggling a dropdown a few times, or by focussing and unfocussing input elements, causing nbSetRequiredKeys++ to increment without limit.
2020-05-19 19:07:48 +01:00
Sijia Zhao
dd23484cf5 Remove need to unfocus/deselect input elements in DlgFromDict before being able to click the "Ok" button
GlobalEventHandlers.onchange only fires when focus is lost. However .oninput fires whenever contents are modified. Original requires "double click" behaviour: first click to deselect the input element, second click to actually click the "Ok" button. Old code results in "Ok" buttons remaining visually disabled thus confusing users even when input elements have been completed
2020-05-19 18:58:52 +01:00
Sijia Zhao
e907c0c897 Prevent special characters in DlgFromDict dictionary causing DOM element selection problems
Use
$.escapeSelector()

Requires jQuery 3.0+
2020-05-19 18:47:16 +01:00
Sijia Zhao
4b064bccc0 Fix DlgFromDict form labels not focussing/selecting corresponding input element
Use
htmlCode += '<label for="' + keyId + '">' + key + '</label>';
2020-05-19 18:42:59 +01:00
Sijia Zhao
d4b52796c9 Fix blurry Pixi canvas
Add
resolution: window.devicePixelRatio,
2020-05-19 18:40:56 +01:00
Alain Pitiot
092829f325 Merge branch 'master' of https://github.com/psychopy/psychojs 2020-05-12 18:34:05 +02:00
Alain Pitiot
1cf40c4d8a _ 2020-05-12 18:31:11 +02:00
Alain Pitiot
feddfa550a
Merge pull request #86 from tpronk/master
Add Blink detection
2020-05-06 08:03:30 +02:00
tpronk
9a11171ba2 Update Util.js 2020-04-30 15:56:31 +02:00
tpronk
926ec69386 Update Util.js
Added Blink detection (from snippet at https://stackoverflow.com/a/9851769)
2020-04-30 15:51:31 +02:00
Alain Pitiot
0ca9e118a4 Merge branch 'master' of github.com:psychopy/psychojs 2020-02-14 08:22:33 +01:00
Alain Pitiot
4942e0156e 2020.1 branch 2020-02-14 08:18:25 +01:00
Jon Peirce
0a5341b982
Fixed typo in readme
Fixes #76
2020-02-06 10:01:17 +00:00
Alain Pitiot
b0dd70222a small edits to README 2019-08-01 14:08:08 +02:00