mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-05-21 12:09:13 +08:00
Merge branch 'cura4.0_header' of github.com:Ultimaker/Cura into cura4.0_header
This commit is contained in:
commit
6ea03d27a4
@ -27,21 +27,25 @@ UM.MainWindow
|
||||
UM.I18nCatalog
|
||||
{
|
||||
id: catalog
|
||||
name:"cura"
|
||||
name: "cura"
|
||||
}
|
||||
|
||||
onWidthChanged:
|
||||
{
|
||||
// If slidebar is collapsed then it should be invisible
|
||||
// otherwise after the main_window resize the sidebar will be fully re-drawn
|
||||
if (sidebar.collapsed){
|
||||
if (sidebar.visible == true){
|
||||
if (sidebar.collapsed)
|
||||
{
|
||||
if (sidebar.visible == true)
|
||||
{
|
||||
sidebar.visible = false
|
||||
sidebar.initialWidth = 0
|
||||
}
|
||||
}
|
||||
else{
|
||||
if (sidebar.visible == false){
|
||||
else
|
||||
{
|
||||
if (sidebar.visible == false)
|
||||
{
|
||||
sidebar.visible = true
|
||||
sidebar.initialWidth = UM.Theme.getSize("sidebar").width
|
||||
}
|
||||
@ -156,7 +160,7 @@ UM.MainWindow
|
||||
Button
|
||||
{
|
||||
id: openFileButton
|
||||
text: catalog.i18nc("@action:button","Open File")
|
||||
text: catalog.i18nc("@action:button", "Open File")
|
||||
iconSource: UM.Theme.getIcon("load")
|
||||
style: UM.Theme.styles.tool_button
|
||||
tooltip: ""
|
||||
@ -352,10 +356,10 @@ UM.MainWindow
|
||||
{
|
||||
//; Remove & re-add the general page as we want to use our own instead of uranium standard.
|
||||
removePage(0);
|
||||
insertPage(0, catalog.i18nc("@title:tab","General"), Qt.resolvedUrl("Preferences/GeneralPage.qml"));
|
||||
insertPage(0, catalog.i18nc("@title:tab", "General"), Qt.resolvedUrl("Preferences/GeneralPage.qml"));
|
||||
|
||||
removePage(1);
|
||||
insertPage(1, catalog.i18nc("@title:tab","Settings"), Qt.resolvedUrl("Preferences/SettingVisibilityPage.qml"));
|
||||
insertPage(1, catalog.i18nc("@title:tab", "Settings"), Qt.resolvedUrl("Preferences/SettingVisibilityPage.qml"));
|
||||
|
||||
insertPage(2, catalog.i18nc("@title:tab", "Printers"), Qt.resolvedUrl("Preferences/MachinesPage.qml"));
|
||||
|
||||
@ -528,7 +532,7 @@ UM.MainWindow
|
||||
id: openDialog;
|
||||
|
||||
//: File open dialog title
|
||||
title: catalog.i18nc("@title:window","Open file(s)")
|
||||
title: catalog.i18nc("@title:window", "Open file(s)")
|
||||
modality: UM.Application.platform == "linux" ? Qt.NonModal : Qt.WindowModal;
|
||||
selectMultiple: true
|
||||
nameFilters: UM.MeshFileHandler.supportedReadFileTypes;
|
||||
|
@ -346,4 +346,4 @@ Rectangle
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -27,7 +27,7 @@ Item
|
||||
Menu
|
||||
{
|
||||
id: fileMenu
|
||||
title: catalog.i18nc("@title:menu menubar:toplevel","&File")
|
||||
title: catalog.i18nc("@title:menu menubar:toplevel", "&File")
|
||||
|
||||
MenuItem
|
||||
{
|
||||
@ -46,7 +46,7 @@ Item
|
||||
MenuItem
|
||||
{
|
||||
id: saveWorkspaceMenu
|
||||
text: catalog.i18nc("@title:menu menubar:file","&Save...")
|
||||
text: catalog.i18nc("@title:menu menubar:file", "&Save...")
|
||||
onTriggered:
|
||||
{
|
||||
var args = { "filter_by_machine": false, "file_type": "workspace", "preferred_mimetypes": "application/vnd.ms-package.3dmanufacturing-3dmodel+xml" };
|
||||
@ -99,7 +99,7 @@ Item
|
||||
|
||||
Menu
|
||||
{
|
||||
title: catalog.i18nc("@title:menu menubar:toplevel","&Edit")
|
||||
title: catalog.i18nc("@title:menu menubar:toplevel", "&Edit")
|
||||
|
||||
MenuItem { action: Cura.Actions.undo }
|
||||
MenuItem { action: Cura.Actions.redo }
|
||||
@ -181,7 +181,7 @@ Item
|
||||
Menu
|
||||
{
|
||||
id: extensionMenu
|
||||
title: catalog.i18nc("@title:menu menubar:toplevel","E&xtensions")
|
||||
title: catalog.i18nc("@title:menu menubar:toplevel", "E&xtensions")
|
||||
|
||||
Instantiator
|
||||
{
|
||||
@ -223,7 +223,7 @@ Item
|
||||
Menu
|
||||
{
|
||||
id: preferencesMenu
|
||||
title: catalog.i18nc("@title:menu menubar:toplevel","P&references")
|
||||
title: catalog.i18nc("@title:menu menubar:toplevel", "P&references")
|
||||
|
||||
MenuItem { action: Cura.Actions.preferences }
|
||||
}
|
||||
@ -231,7 +231,7 @@ Item
|
||||
Menu
|
||||
{
|
||||
id: helpMenu
|
||||
title: catalog.i18nc("@title:menu menubar:toplevel","&Help")
|
||||
title: catalog.i18nc("@title:menu menubar:toplevel", "&Help")
|
||||
|
||||
MenuItem { action: Cura.Actions.showProfileFolder }
|
||||
MenuItem { action: Cura.Actions.documentation }
|
||||
|
@ -11,9 +11,9 @@ import Cura 1.0 as Cura
|
||||
|
||||
import "../components"
|
||||
|
||||
// This item contains the views selector, a combobox that is dinamically created from
|
||||
// the list of available Views (packages that create different visualizactions of the
|
||||
// scene. Aside the selector, there is a row of buttons that change the orientation of the view.
|
||||
// This item contains the views selector, a combobox that is dynamically created from
|
||||
// the list of available Views (packages that create different visualizations of the
|
||||
// scene). Aside from the selector, there is a row of buttons that change the orientation of the view.
|
||||
Item
|
||||
{
|
||||
id: applicationViewsSelector
|
||||
@ -25,7 +25,8 @@ Item
|
||||
{
|
||||
id: viewModeButton
|
||||
|
||||
anchors {
|
||||
anchors
|
||||
{
|
||||
verticalCenter: parent.verticalCenter
|
||||
right: parent.right
|
||||
rightMargin: UM.Theme.getSize("default_margin").width
|
||||
@ -51,15 +52,16 @@ Item
|
||||
{
|
||||
for (var i = 0; i < model.rowCount(); i++)
|
||||
{
|
||||
if (model.getItem(i).active) {
|
||||
return i
|
||||
if (model.getItem(i).active)
|
||||
{
|
||||
return i;
|
||||
}
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
// set the active index
|
||||
function setActiveIndex (index)
|
||||
function setActiveIndex(index)
|
||||
{
|
||||
UM.Controller.setActiveView(index)
|
||||
// the connection to UM.ActiveView will trigger update so there is no reason to call it manually here
|
||||
|
Loading…
x
Reference in New Issue
Block a user