Created
December 1, 2014 06:39
-
-
Save js1972/b69014e0ef9fd1bc4444 to your computer and use it in GitHub Desktop.
Help functions to determine if a given control is an XML View and to find the XML View that a control is in...
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
isXMLView = function(oControl) { | |
return oControl.getMetadata().getName() === "sap.ui.core.mvc.XMLView"; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
myView = function(oControl) { | |
return isXMLView(oControl) ? oControl : myView(oControl.getParent()); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment