View Issue Details

IDProjectCategoryView StatusLast Update
0019179MMW 5Extensions frameworkpublic2022-08-05 11:27
Reporterzvezdan Assigned To 
PrioritylowSeverityminorReproducibilityN/A
Status closedResolutionreopened 
Summary0019179: Replacement for SDB.CursorType = -11 'Hourglass needed
DescriptionFor those unfamiliar, that is the hourglass mouse cursor, indicating an execution of a long performing task (http://mediamonkey.com/wiki/ISDBApplication::CursorType).

It should appear immediately when executed without any additional code, which was not the case with the old API that required SDB.ProcessMessages to be put before and/or after the mentioned statement for changes of cursor to take an effect.

Also, -19 (App start) could be needed, and of course 0 (The default look). Well, maybe scripters would want to use any other cursor as well (http://mediamonkey.com/wiki/Possible_Cursor_Types).
TagsNo tags attached.
Fixed in build

Activities

Ludek

2022-08-01 18:42

developer   ~0068954

Last edited: 2022-08-01 18:43

Feel free to use the cursor JS/HTML/CSS property: https://www.w3schools.com/cssref/pr_class_cursor.asp

Or (better) the progress circle:
var progress = app.backgroundTasks.createNew();
progress.leadingText = 'My progress';
progress.value = 0.5;
...
progress.terminate();


or alternatively the progress window (search for window.uitools.showProgressWindow(); in the code).

zvezdan

2022-08-01 18:52

updater   ~0068955

The cursor property of particular HTML elements is not what I am asking for. I want to change mouse cursor which will be the same within the program whatever HTML element is under it.

Do you suggest that I change cusror property of all HTML elements that the program consists to have the same behavior as MM4 and other programs having such cursor.

Of course I am using the progress circle, you don't need to tell me such trivial things. It is not the same as the mouse cursor either. It could be covered by dialog box and not visible.

I am also using the progress div element in my dialog box (data-control-class="ProgressBar"). But again, it is not the same as mouse cursor clearly indicating that program is busy.

Ludek

2022-08-01 19:15

developer   ~0068958

Yes, the cursor property can be set to any element, even to document.body like this:

document.body.style.cursor = "progress";

zvezdan

2022-08-01 19:44

updater   ~0068959

First of all, that is not the hourglass cursor, but -19: App start.

Secondly, take a look at the animated screenshot and see how it is sporadic instead to be the same over all elements.
2022-08-01_21-34-28.gif (156,294 bytes)   
2022-08-01_21-34-28.gif (156,294 bytes)   

Ludek

2022-08-02 18:00

developer   ~0068962

Last edited: 2022-08-02 19:03

OK, then you could put another DIV with CSS class 'layer' and make it visible only when your script is busy (and set the needed cursor for that layer)

Not sure what do you mean by -19: App start, but both 'progress' and 'wait' cursors looks same here and indicates that the program is busy ( viz https://www.w3schools.com/cssref/tryit.asp?filename=trycss_cursor )

zvezdan

2022-08-02 21:46

updater   ~0068963

I posted a link with possible cursor types available in MM4. It is published on wiki of your own program.

These two cursors are not the same. The hourglass cursor is like 'wait' for HTML elements with only a circle on Vista and 7 (it was a rotating hourglass in XP and older, I don't know how it looks in newer ones). It is used when the program is completely busy and UI is not accessible at all. The App start cursor is like 'progress' and has an arrow pointer with a smaller circle. That one is used when the program is busy, but its UI is not blocked.

Your workaround with a div element requires from every scripter wanting such thing to mess around with it. I expected that you do something about it natively, but since you don't think it is necessary, just forget it and close this issue.