Author |
Message |
12/09/2019 11:57:33
|
levy
Power User
Joined: 12/03/2008 16:38:22
Messages: 308
Location: XpertCenter
Offline
|
Hi Björn
With CC version 20190820, I have detected a different behavior of WorkpageContainer's method closeAllWorkpages() that should force the closing of all workpages. Now the closing is prevented for wokpages with no close supported. A warning popup window is opened instead. This obeys to the following code in the private method removeWorkpageLOCAL(IWorkpage workpage, boolean withCloseForced, Runnable continueOperation):
if (workpage.isCloseSupported() == false)
{
OKPopup.createInstance(I18N.getString("WP_titleWorkpageCannotBeClosed"),I18N.getString("WP_textWorkpageCannotBeClosed"));
return true;
}
I would expect the clause to be (workpage.isCloseSupported() == false) && (withCloseForced == false).
Otherwise, I must workaround by setting for every workpage isCloseSupported = true before calling closeAllWorkpages().
Can you please take a look at it?
Regards, Daniel
|
|
|
26/09/2019 03:57:48
|
CaptainCasa
Power User
Joined: 21/11/2007 12:23:06
Messages: 5555
Offline
|
Hi Daniel,
we treted the bahavior as bug: a page says "closeSupported = false" and then you can close by API... But I agree: your intentaon of using "closeSupported = false" is, that there is no renderening of corresponding icons + that you do the closing via your code internally (using the API).
We will provide some solution on this with next update, so that we internally know if some API was called by own processing (=> we will never close a page with closeSupported = true) or by "outside" processing (=> if someone calls the processing: do it!). Should be part of next update.
Thansk + Regards! Björn
|
Björn Müller, CaptainCasa GmbH |
|
|
03/12/2019 09:35:24
|
levy
Power User
Joined: 12/03/2008 16:38:22
Messages: 308
Location: XpertCenter
Offline
|
Hi Björn
I have verified CC version 20191120_2.
On the one hand, the warning popup is not opened anymore.
But, on the other hand, the closing is still prevented for pages with no close supported.
So I have to maintain the workaround described previously.
Could you please check?
Kind regards, Daniel
|
|
|
13/01/2020 09:56:56
|
levy
Power User
Joined: 12/03/2008 16:38:22
Messages: 308
Location: XpertCenter
Offline
|
Hi Björn
I want to download a new CC version because of a couple of issues you resolved. Unfortunately this one is still missing to be solved, I am waiting for it. I would appreciate this issue beeing checked.
Kind regards, Daniel
|
|
|
13/01/2020 10:39:11
|
Admin
Power User
Joined: 21/11/2007 11:36:10
Messages: 38
Offline
|
Hi Daniel,
sorry on this. To be honest, we had some problems to figure out if a call is coming from outside or if it is some internal call...
What we now provide: a new method on IWorkpageContainer:
Code:
public void closeWorkpage(IWorkpage workpage, boolean alsoCloseWorkpageWithNoCloseSupported);
public void closeWorkpageForced(IWorkpage workpage, boolean alsoCloseWorkpageWithNoCloseSupported);
So you can explicitly control if you want to override the default behavior of not deleting these pages.
Is available with next update (expected for tomorrow morning).
Thanks + Regards! Björn
|
|
|
|