Issue 22829 - com::sun::star::frame::XStorable::dropLocation()
Summary: com::sun::star::frame::XStorable::dropLocation()
Status: CLOSED WONT_FIX
Alias: None
Product: App Dev
Classification: Unclassified
Component: api (show other issues)
Version: 3.3.0 or older (OOo)
Hardware: All All
: P3 Trivial
Target Milestone: ---
Assignee: Mathias_Bauer
QA Contact: issues@api
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-11-25 10:38 UTC by em2
Modified: 2013-02-24 21:07 UTC (History)
1 user (show)

See Also:
Issue Type: ENHANCEMENT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description em2 2003-11-25 10:38:46 UTC
Currently there is no way, after calling XStorable::storeToURL(),
for returning a document into virgin state (not loaded and not saved),
that is, making hasLocation() return false.

I suggest adding XStorable::dropLocation().
Comment 1 ooo 2003-11-26 11:10:34 UTC
XStorable cannot be extended, it would be incompatible.  Thus, only a
new interface would be possible.

But what is the real difference to load a new document with the
appropriate  factory URL?  Ok, you will get a new document object, but
the advantage is so minor that I don't think I can find support from
the applications to implement this feature.
Comment 2 ooo 2003-11-26 11:11:18 UTC
assigning back to reporter
Comment 4 em2 2003-11-26 14:02:40 UTC
(Oops, ignore my previous comment, wrong button.)

First,s/storeToURL/storeAsURL/ in my initial message.

Next, there's a situation where storeAsURL is required,
but that can't be undone without XStorable2::dropLocation():

http://api.openoffice.org/servlets/ReadMsg?msgId=953025&listName=dev
Comment 5 em2 2003-11-26 14:09:11 UTC
There might be a situation where an Add-on wants to disable
Save and Reload, forcing the user to Save-As.
(Poor man's templates.)
Comment 6 ooo 2004-01-29 15:33:16 UTC
you can explicitely disable "save" from UI with an XDispatchInterceptor, this feature is redundant
Comment 7 em2 2004-01-29 16:07:00 UTC
Apparently, you only looked at my last comment. Disabling "Save" doesn't
help for this problem:

There's a situation where storeAsURL is required, but that can't be
undone without XStorable2::dropLocation():

http://api.openoffice.org/servlets/ReadMsg?msgId=953025&listName=dev
Comment 8 ooo 2004-02-02 15:51:16 UTC
I may have misunderstood what you actually want.  Your term "virgin state" confused me. If you want 
just to make the document think it has no location attached withouth actuelly clearing it, then this might 
be a proper requirement.  But I would not call that "virgin".  
.
Comment 9 ooo 2004-02-02 15:52:11 UTC
forwarding to responsible developer
Comment 10 andreas.schluens 2004-02-04 05:30:27 UTC
forwarding to responsible developer
Comment 11 Mathias_Bauer 2004-02-05 13:34:10 UTC
Why can't you use storeToURL instead of storeAsURL? This wouldn't need a
"dropLocation". I don't see the meaning in using a method that explicitly sets a
location and remove that location afterwards if there is another method that
does exactly the same but doesn't set a location.

Whith a dispatch interceptor you could even convert our "SaveAs" GUI function to
use storeToURL instead of storeAsURL.
Comment 12 Mathias_Bauer 2004-03-26 17:22:38 UTC
.
Comment 13 Mathias_Bauer 2004-03-26 17:22:53 UTC
Left without any reaction I decided to close this by myself.