From 5a802d62cbe8fb7b1c3355cfb35573d37b516a22 Mon Sep 17 00:00:00 2001 From: coderaiser Date: Mon, 20 Jan 2014 06:03:18 -0500 Subject: [PATCH] feature(dom) add getCurrentOwner --- lib/client/dom.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/lib/client/dom.js b/lib/client/dom.js index 20716c6f..067aecec 100644 --- a/lib/client/dom.js +++ b/lib/client/dom.js @@ -1000,6 +1000,19 @@ var CloudCmd, Util, DOM, CloudFunc, Dialog; return lRet; }; + /** + * @pCurrentFile + */ + this.getCurrentOwner = function(pCurrentFile) { + var ret, + current = pCurrentFile || this.getCurrentFile(), + owner = this.getByClass('owner', current)[0]; + + ret = owner.textContent; + + return ret; + }; + /** * unified way to get current file content *