hi...i using metro ui window in project..
how window close by function??
for example:
win.close();
win.remove();
win.onClose();
this not working!!!
how window close
- olton
- Site Admin
- Posts: 170
- Joined: Mon Apr 09, 2018 6:19 pm
- Location: Kiev, Ukraine
- Status: Offline
1. Get window instance and call method close
2. Use object Metro.window
https://metroui.org.ua/windows.html
Code: Select all
var win = $(el_selector).data('window');
win.close();
Code: Select all
Metro.window.close(el_selector)
-
- Posts: 1
- Joined: Wed May 30, 2018 9:31 am
- Status: Offline
i am triying to close the window too, this is my code:
Desktop.createWindow({
width: $(window).width()
,height: $(window).height()
,icon: "<span class='mif-search'></span>"
,title: "Buscar Desarrollador"
,content: tbDesarrollador
});
where is my selector? (el_selector)??
var win = $(el_selector).data('window');
win.close();
Desktop.createWindow({
width: $(window).width()
,height: $(window).height()
,icon: "<span class='mif-search'></span>"
,title: "Buscar Desarrollador"
,content: tbDesarrollador
});
where is my selector? (el_selector)??
var win = $(el_selector).data('window');
win.close();
- olton
- Site Admin
- Posts: 170
- Joined: Mon Apr 09, 2018 6:19 pm
- Location: Kiev, Ukraine
- Status: Offline
to get window instance from this function, you must rewrite method createWindow for returning window instance.
https://github.com/olton/Metro-UI-CSS/b ... top.js#L40
https://github.com/olton/Metro-UI-CSS/b ... top.js#L40