[PE] Show current hyperlink settings
This commit is contained in:
parent
e826d8a8e1
commit
c70db921eb
|
@ -1357,7 +1357,6 @@ define([
|
|||
|
||||
text = me.api.can_AddHyperlink();
|
||||
|
||||
if (text !== false) {
|
||||
var _arr = [];
|
||||
for (var i=0; i<me.api.getCountPages(); i++) {
|
||||
_arr.push({
|
||||
|
@ -1365,15 +1364,24 @@ define([
|
|||
value: i
|
||||
});
|
||||
}
|
||||
if (text !== false) {
|
||||
props = new Asc.CHyperlinkProperty();
|
||||
props.put_Text(text);
|
||||
} else {
|
||||
var selectedElements = me.api.getSelectedElements();
|
||||
if (selectedElements && _.isArray(selectedElements)){
|
||||
_.each(selectedElements, function(el, i) {
|
||||
if (selectedElements[i].get_ObjectType() == Asc.c_oAscTypeSelectElement.Hyperlink)
|
||||
props = selectedElements[i].get_ObjectValue();
|
||||
});
|
||||
}
|
||||
}
|
||||
if (props) {
|
||||
win = new PE.Views.HyperlinkSettingsDialog({
|
||||
api: me.api,
|
||||
handler: handlerDlg,
|
||||
slides: _arr
|
||||
});
|
||||
|
||||
props = new Asc.CHyperlinkProperty();
|
||||
props.put_Text(text);
|
||||
|
||||
win.show();
|
||||
win.setSettings(props);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue