Skip to content
This repository was archived by the owner on Dec 20, 2023. It is now read-only.

Commit fd674f1

Browse files
author
Barry de Graaff
committed

File tree

3 files changed

+14
-11
lines changed

3 files changed

+14
-11
lines changed

zimlet/OwnCloudFolderPicker.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ function OwnCloudFolderPicker(parent, zimletCtxt, davConnector, ownCloudConnecto
7575
if(arguments[1].dwtObj)
7676
{
7777
zimletInstance.OwnCloudFolderPicker.selectedDavResource = arguments[1].dwtObj._data.DavResource;
78+
zimletInstance.OwnCloudFolderPicker.selectedTreeObj = arguments[1].dwtObj;
7879
this._davConnector.propfind(
7980
arguments[1].dwtObj._data.DavResource.getHref(),
8081
1,

zimlet/tk_barrydegraaff_owncloud_zimlet.js

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -445,17 +445,19 @@ ownCloudZimlet.prototype._newFolderCallback = function(folder, input, dialog, ev
445445
this._davConnector.mkcol(
446446
"/"+(folderHref + inputValue).replace(tk_barrydegraaff_owncloud_zimlet_HandlerObject.settings['owncloud_zimlet_server_path'], ""),
447447
new AjxCallback(this, function(dialog, result) {
448-
dialog.popdown();
448+
var zimletInstance = appCtxt._zimletMgr.getZimletByName('tk_barrydegraaff_owncloud_zimlet').handlerObject;
449+
450+
zimletInstance.OwnCloudFolderPicker._davConnector.propfind(
451+
zimletInstance.OwnCloudFolderPicker.selectedDavResource.getHref(),
452+
1,
453+
new AjxCallback(
454+
zimletInstance.OwnCloudFolderPicker,
455+
zimletInstance.OwnCloudFolderPicker._renderPropFind,
456+
[zimletInstance.OwnCloudFolderPicker.selectedDavResource.getHref(), zimletInstance.OwnCloudFolderPicker.selectedTreeObj]
457+
), zimletInstance.OwnCloudFolderPicker._zimletCtxt._defaultPropfindErrCbk
458+
);
449459

450-
zimletInstance.OwnCloudFolderPicker = new OwnCloudFolderPicker(
451-
zimletInstance._folderPickerDialog,
452-
zimletInstance,
453-
zimletInstance._davConnector,
454-
zimletInstance._ownCloudConnector,
455-
new OwnCloudCommons(zimletInstance._davConnector, zimletInstance._ownCloudConnector)
456-
);
457-
document.getElementById('ownCloudZimletFolderPicker').innerHTML = "";
458-
zimletInstance.OwnCloudFolderPicker.reparentHtmlElement(document.getElementById('ownCloudZimletFolderPicker'));
460+
dialog.popdown();
459461
}, [dialog])
460462
);
461463
};

zimlet/tk_barrydegraaff_owncloud_zimlet.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ along with this program. If not, see http://www.gnu.org/licenses/.
2323
2424
-->
2525
<zimlet name="tk_barrydegraaff_owncloud_zimlet"
26-
version="1.2.0"
26+
version="1.2.1"
2727
target="main compose-window view-window"
2828
label="WebDAV"
2929
description="Attach from and save to WebDAV">

0 commit comments

Comments
 (0)