Fix some crashes and issues in the Toolbox when working with no

internet connection.
This commit is contained in:
Diego Prado Gesto 2018-05-11 15:23:40 +02:00
parent 675b5b1997
commit fa97d5830b
3 changed files with 52 additions and 45 deletions

View file

@ -24,7 +24,8 @@ Item
ToolboxTabButton
{
text: catalog.i18nc("@title:tab", "Plugins")
active: toolbox.viewCategory == "plugin"
active: toolbox.viewCategory == "plugin" && enabled
enabled: toolbox.viewPage != "loading" && toolbox.viewPage != "errored"
onClicked:
{
toolbox.filterModelByProp("packages", "type", "plugin")
@ -35,7 +36,8 @@ Item
ToolboxTabButton
{
text: catalog.i18nc("@title:tab", "Materials")
active: toolbox.viewCategory == "material"
active: toolbox.viewCategory == "material" && enabled
enabled: toolbox.viewPage != "loading" && toolbox.viewPage != "errored"
onClicked:
{
toolbox.filterModelByProp("authors", "package_types", "material")