.. | .. |
---|
72 | 72 | } |
---|
73 | 73 | } |
---|
74 | 74 | |
---|
| 75 | + public Composite CreateCameras() |
---|
| 76 | + { |
---|
| 77 | + Composite cams = new cTemplate(); |
---|
| 78 | + cams.name = "Cameras"; |
---|
| 79 | + copy.insertElementAt(cams, 0); |
---|
| 80 | + |
---|
| 81 | + cams.addChild(new Camera()); |
---|
| 82 | + cams.addChild(new Camera(1)); |
---|
| 83 | + cams.addChild(new Camera(2)); |
---|
| 84 | + cams.addChild(new Camera(3)); |
---|
| 85 | + cams.addChild(new Camera(4)); |
---|
| 86 | + |
---|
| 87 | + return cams; |
---|
| 88 | + } |
---|
| 89 | + |
---|
75 | 90 | public cGridBag GetSeparator() |
---|
76 | 91 | { |
---|
77 | 92 | cGridBag separator = new cGridBag(); |
---|
.. | .. |
---|
83 | 98 | cButton GetButton(String name, boolean border) |
---|
84 | 99 | { |
---|
85 | 100 | ImageIcon icon = GetIcon(name); |
---|
86 | | - if (icon != null) |
---|
| 101 | + if (icon != null || name.contains("/")) |
---|
87 | 102 | return new cButton(icon, border); |
---|
88 | 103 | else |
---|
89 | 104 | return new cButton(name, border); |
---|
.. | .. |
---|
1318 | 1333 | |
---|
1319 | 1334 | //if (copy.pinned) |
---|
1320 | 1335 | { |
---|
1321 | | - pinButton = GetToggleButton("icons/pin.png", !Grafreed.NIMBUSLAF); |
---|
| 1336 | + pinButton = GetToggleButton("icons/pin.png", !Globals.NIMBUSLAF); |
---|
1322 | 1337 | pinButton.setSelected(copy.pinned); |
---|
1323 | 1338 | cGridBag t = new cGridBag(); |
---|
1324 | 1339 | t.preferredWidth = 2; |
---|
.. | .. |
---|
1550 | 1565 | |
---|
1551 | 1566 | if (cam == null || !(copy.get(0) instanceof cGroup)) |
---|
1552 | 1567 | { |
---|
1553 | | - if (Globals.DEBUG) |
---|
1554 | | - System.out.println("CREATE CAMERAS"); |
---|
1555 | | - cams = new cTemplate(); |
---|
1556 | | - cams.name = "Cameras"; |
---|
1557 | | - copy.insertElementAt(cams, 0); |
---|
1558 | | - //cams.parent = copy; |
---|
1559 | | - |
---|
1560 | | - cam = new Camera(); // LA.newVector(3, 2, 1)); |
---|
1561 | | - cams.addChild(cam); |
---|
1562 | | - cam = new Camera(1); |
---|
1563 | | - cams.addChild(cam); |
---|
1564 | | - cam = new Camera(2); |
---|
1565 | | - cams.addChild(cam); |
---|
1566 | | - cam = new Camera(3); |
---|
1567 | | - cams.addChild(cam); |
---|
1568 | | - cam = new Camera(4); // Light |
---|
1569 | | - cams.addChild(cam); |
---|
| 1568 | + if (Globals.DEBUG) |
---|
| 1569 | + System.out.println("CREATE CAMERAS"); |
---|
| 1570 | + cams = CreateCameras(); |
---|
1570 | 1571 | } else |
---|
1571 | 1572 | { |
---|
1572 | 1573 | cams = (cGroup) copy.get(0); |
---|
.. | .. |
---|
1638 | 1639 | |
---|
1639 | 1640 | resetTransformPanel.preferredHeight = 2; |
---|
1640 | 1641 | |
---|
1641 | | - cButton resetTransform = GetButton("Reset all", !Grafreed.NIMBUSLAF); |
---|
| 1642 | + cButton resetTransform = GetButton("Reset all", !Globals.NIMBUSLAF); |
---|
| 1643 | + resetTransform.setToolTipText("Reset Translation, Rotation and Scale"); |
---|
1642 | 1644 | resetTransform.addMouseListener(new MouseAdapter() |
---|
1643 | 1645 | { |
---|
1644 | 1646 | public void mouseClicked(MouseEvent e) |
---|
.. | .. |
---|
1648 | 1650 | }); |
---|
1649 | 1651 | resetTransformPanel.add(resetTransform); |
---|
1650 | 1652 | |
---|
1651 | | - resetTransform = GetButton("T only", !Grafreed.NIMBUSLAF); |
---|
| 1653 | + resetTransform = GetButton("T only", !Globals.NIMBUSLAF); |
---|
| 1654 | + resetTransform.setToolTipText("Reset Translation only"); |
---|
1652 | 1655 | resetTransform.addMouseListener(new MouseAdapter() |
---|
1653 | 1656 | { |
---|
1654 | 1657 | public void mouseClicked(MouseEvent e) |
---|
.. | .. |
---|
1658 | 1661 | }); |
---|
1659 | 1662 | resetTransformPanel.add(resetTransform); |
---|
1660 | 1663 | |
---|
1661 | | - resetTransform = GetButton("RS only", !Grafreed.NIMBUSLAF); |
---|
| 1664 | + resetTransform = GetButton("RS only", !Globals.NIMBUSLAF); |
---|
| 1665 | + resetTransform.setToolTipText("Reset Rotation and Scale only"); |
---|
1662 | 1666 | resetTransform.addMouseListener(new MouseAdapter() |
---|
1663 | 1667 | { |
---|
1664 | 1668 | public void mouseClicked(MouseEvent e) |
---|
.. | .. |
---|
1715 | 1719 | |
---|
1716 | 1720 | //JScrollPane tmp = new JScrollPane(ctrlPanel, ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED, ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); |
---|
1717 | 1721 | //tmp.setName("Edit"); |
---|
| 1722 | + objectPanel.add(skyboxPanel); |
---|
| 1723 | + objectPanel.setIconAt(0, GetIcon("icons/skybox.jpg")); |
---|
| 1724 | + objectPanel.setToolTipTextAt(0, "Backgrounds"); |
---|
| 1725 | + |
---|
1718 | 1726 | objectPanel.add(toolboxPanel); |
---|
1719 | | - objectPanel.setIconAt(0, GetIcon("icons/primitives.png")); |
---|
1720 | | - objectPanel.setToolTipTextAt(0, "Objects & textures"); |
---|
| 1727 | + objectPanel.setIconAt(1, GetIcon("icons/primitives.png")); |
---|
| 1728 | + objectPanel.setToolTipTextAt(1, "Objects & textures"); |
---|
1721 | 1729 | |
---|
1722 | 1730 | objectPanel.add(materialPanel); |
---|
1723 | | - objectPanel.setIconAt(1, GetIcon("icons/material.png")); |
---|
1724 | | - objectPanel.setToolTipTextAt(1, "Material"); |
---|
| 1731 | + objectPanel.setIconAt(2, GetIcon("icons/material.png")); |
---|
| 1732 | + objectPanel.setToolTipTextAt(2, "Material"); |
---|
1725 | 1733 | |
---|
1726 | | - objectPanel.add(skyboxPanel); |
---|
1727 | | - objectPanel.setIconAt(2, GetIcon("icons/skybox.jpg")); |
---|
1728 | | - objectPanel.setToolTipTextAt(2, "Backgrounds"); |
---|
1729 | | - |
---|
1730 | 1734 | // JPanel north = new JPanel(new BorderLayout()); |
---|
1731 | 1735 | // north.setName("Edit"); |
---|
1732 | 1736 | // north.add(ctrlPanel, BorderLayout.NORTH); |
---|
1733 | 1737 | // objectPanel.add(north); |
---|
1734 | 1738 | objectPanel.add(editPanel); |
---|
1735 | | - objectPanel.setIconAt(3, GetIcon("icons/write.png")); |
---|
| 1739 | + objectPanel.setIconAt(3, GetIcon("icons/writewhite.png")); |
---|
1736 | 1740 | objectPanel.setToolTipTextAt(3, "Edit controls"); |
---|
1737 | 1741 | |
---|
1738 | 1742 | objectPanel.add(transformPanel); |
---|
.. | .. |
---|
1741 | 1745 | |
---|
1742 | 1746 | patchMaterial = true; |
---|
1743 | 1747 | cameraView.patchMaterial = this; |
---|
1744 | | - objectPanel.setSelectedIndex(1); |
---|
| 1748 | + objectPanel.setSelectedIndex(2); |
---|
1745 | 1749 | |
---|
1746 | 1750 | /* |
---|
1747 | 1751 | aConstraints.gridx = 0; |
---|
.. | .. |
---|
1773 | 1777 | |
---|
1774 | 1778 | AddOptions(optionsPanel); //, aConstraints); |
---|
1775 | 1779 | |
---|
1776 | | - tabbedPane.add(optionsPanel); |
---|
1777 | | - |
---|
1778 | 1780 | tabbedPane.add(FSPane = new cFileSystemPane(this)); |
---|
1779 | 1781 | |
---|
| 1782 | + tabbedPane.add(optionsPanel); |
---|
| 1783 | + |
---|
1780 | 1784 | scenePanel.add(tabbedPane); |
---|
1781 | 1785 | |
---|
1782 | | - //if (Globals.ADVANCED) |
---|
1783 | | -// tabbedPane.add(infoPanel); |
---|
1784 | | -// tabbedPane.setIconAt(3, GetIcon("icons/info.png")); |
---|
1785 | | -// tabbedPane.setToolTipTextAt(3, "Information"); |
---|
| 1786 | + cGridBag creditsPanel = new cGridBag().setVertical(true); |
---|
| 1787 | + creditsPanel.setName("Credits"); |
---|
1786 | 1788 | |
---|
| 1789 | + cLabel ogaLabel = new cLabel(" Most Skyboxes courtesy of OpenGameArt!", !Globals.NIMBUSLAF); |
---|
| 1790 | + creditsPanel.add(ogaLabel); |
---|
| 1791 | + |
---|
| 1792 | + cButton opengameartButton; |
---|
| 1793 | + creditsPanel.add(opengameartButton = GetButton("icons/sara-logo.png", !Globals.NIMBUSLAF)); |
---|
| 1794 | + opengameartButton.setToolTipText("https://opengameart.org"); |
---|
| 1795 | + |
---|
| 1796 | + opengameartButton.addMouseListener(new MouseAdapter() |
---|
| 1797 | + { |
---|
| 1798 | + public void mouseClicked(MouseEvent e) |
---|
| 1799 | + { |
---|
| 1800 | + try |
---|
| 1801 | + { |
---|
| 1802 | + Desktop.getDesktop().browse(new java.net.URI("https://opengameart.org/")); |
---|
| 1803 | + } catch (Exception e1) |
---|
| 1804 | +// } catch (java.io.IOException | java.net.URISyntaxException e1) |
---|
| 1805 | + { |
---|
| 1806 | + e1.printStackTrace(); |
---|
| 1807 | + } |
---|
| 1808 | + } |
---|
| 1809 | + }); |
---|
| 1810 | + |
---|
| 1811 | + for (int i=10; --i>=0;) |
---|
| 1812 | + { |
---|
| 1813 | + creditsPanel.add(new cGridBag()); |
---|
| 1814 | + } |
---|
| 1815 | + |
---|
| 1816 | + tabbedPane.add(creditsPanel); |
---|
| 1817 | + tabbedPane.setToolTipTextAt(3, "Credits"); |
---|
| 1818 | + |
---|
| 1819 | + if (Globals.ADVANCED) |
---|
| 1820 | + { |
---|
| 1821 | + tabbedPane.add(infoPanel); |
---|
| 1822 | + tabbedPane.setIconAt(4, GetIcon("icons/info.png")); |
---|
| 1823 | + tabbedPane.setToolTipTextAt(4, "Information"); |
---|
| 1824 | + } |
---|
| 1825 | + |
---|
1787 | 1826 | /* |
---|
1788 | 1827 | cTree jTree = new cTree(null); |
---|
1789 | 1828 | ToolTipManager.sharedInstance().registerComponent(jTree); |
---|
.. | .. |
---|
1929 | 1968 | { |
---|
1930 | 1969 | cGridBag presetpanel = new cGridBag().setVertical(true); |
---|
1931 | 1970 | |
---|
1932 | | - cLabel skin = GetLabel("icons/shadericons/shadericon00000.png", !Grafreed.NIMBUSLAF); |
---|
| 1971 | + cLabel skin = GetLabel("icons/shadericons/shadericon00000.png", !Globals.NIMBUSLAF); |
---|
1933 | 1972 | skin.setToolTipText("Skin"); |
---|
1934 | 1973 | skin.addMouseListener(new MouseAdapter() |
---|
1935 | 1974 | { |
---|
.. | .. |
---|
1967 | 2006 | }); |
---|
1968 | 2007 | presetpanel.add(skin); |
---|
1969 | 2008 | |
---|
1970 | | - cLabel lambert = GetLabel("icons/shadericons/shadericon00002.png", !Grafreed.NIMBUSLAF); |
---|
| 2009 | + cLabel lambert = GetLabel("icons/shadericons/shadericon00002.png", !Globals.NIMBUSLAF); |
---|
1971 | 2010 | lambert.setToolTipText("Diffuse"); |
---|
1972 | 2011 | lambert.addMouseListener(new MouseAdapter() |
---|
1973 | 2012 | { |
---|
.. | .. |
---|
1985 | 2024 | }); |
---|
1986 | 2025 | presetpanel.add(lambert); |
---|
1987 | 2026 | |
---|
1988 | | - cLabel diffuse2 = GetLabel("icons/shadericons/shadericon00003.png", !Grafreed.NIMBUSLAF); |
---|
| 2027 | + cLabel diffuse2 = GetLabel("icons/shadericons/shadericon00003.png", !Globals.NIMBUSLAF); |
---|
1989 | 2028 | diffuse2.setToolTipText("Diffuse2"); |
---|
1990 | 2029 | diffuse2.addMouseListener(new MouseAdapter() |
---|
1991 | 2030 | { |
---|
.. | .. |
---|
2003 | 2042 | }); |
---|
2004 | 2043 | presetpanel.add(diffuse2); |
---|
2005 | 2044 | |
---|
2006 | | - cLabel diffusemoon = GetLabel("icons/shadericons/shadericon00004.png", !Grafreed.NIMBUSLAF); |
---|
| 2045 | + cLabel diffusemoon = GetLabel("icons/shadericons/shadericon00004.png", !Globals.NIMBUSLAF); |
---|
2007 | 2046 | diffusemoon.setToolTipText("Moon"); |
---|
2008 | 2047 | diffusemoon.addMouseListener(new MouseAdapter() |
---|
2009 | 2048 | { |
---|
.. | .. |
---|
2021 | 2060 | }); |
---|
2022 | 2061 | presetpanel.add(diffusemoon); |
---|
2023 | 2062 | |
---|
2024 | | - cLabel diffusemoon2 = GetLabel("icons/shadericons/shadericon00005.png", !Grafreed.NIMBUSLAF); |
---|
| 2063 | + cLabel diffusemoon2 = GetLabel("icons/shadericons/shadericon00005.png", !Globals.NIMBUSLAF); |
---|
2025 | 2064 | diffusemoon2.setToolTipText("Moon2"); |
---|
2026 | 2065 | diffusemoon2.addMouseListener(new MouseAdapter() |
---|
2027 | 2066 | { |
---|
.. | .. |
---|
2039 | 2078 | }); |
---|
2040 | 2079 | presetpanel.add(diffusemoon2); |
---|
2041 | 2080 | |
---|
2042 | | - cLabel diffusemoon3 = GetLabel("icons/shadericons/shadericon00006.png", !Grafreed.NIMBUSLAF); |
---|
| 2081 | + cLabel diffusemoon3 = GetLabel("icons/shadericons/shadericon00006.png", !Globals.NIMBUSLAF); |
---|
2043 | 2082 | diffusemoon3.setToolTipText("Moon3"); |
---|
2044 | 2083 | diffusemoon3.addMouseListener(new MouseAdapter() |
---|
2045 | 2084 | { |
---|
.. | .. |
---|
2057 | 2096 | }); |
---|
2058 | 2097 | presetpanel.add(diffusemoon3); |
---|
2059 | 2098 | |
---|
2060 | | - cLabel diffusesheen = GetLabel("icons/shadericons/shadericon00007.png", !Grafreed.NIMBUSLAF); |
---|
| 2099 | + cLabel diffusesheen = GetLabel("icons/shadericons/shadericon00007.png", !Globals.NIMBUSLAF); |
---|
2061 | 2100 | diffusesheen.setToolTipText("Sheen"); |
---|
2062 | 2101 | diffusesheen.addMouseListener(new MouseAdapter() |
---|
2063 | 2102 | { |
---|
.. | .. |
---|
2074 | 2113 | }); |
---|
2075 | 2114 | presetpanel.add(diffusesheen); |
---|
2076 | 2115 | |
---|
2077 | | - cLabel rough = GetLabel("icons/shadericons/shadericon00001.png", !Grafreed.NIMBUSLAF); |
---|
| 2116 | + cLabel rough = GetLabel("icons/shadericons/shadericon00001.png", !Globals.NIMBUSLAF); |
---|
2078 | 2117 | rough.setToolTipText("Rough metal"); |
---|
2079 | 2118 | rough.addMouseListener(new MouseAdapter() |
---|
2080 | 2119 | { |
---|
.. | .. |
---|
2092 | 2131 | }); |
---|
2093 | 2132 | presetpanel.add(rough); |
---|
2094 | 2133 | |
---|
2095 | | - cLabel rough2 = GetLabel("icons/shadericons/shadericon00013.png", !Grafreed.NIMBUSLAF); |
---|
| 2134 | + cLabel rough2 = GetLabel("icons/shadericons/shadericon00013.png", !Globals.NIMBUSLAF); |
---|
2096 | 2135 | rough2.setToolTipText("Medium metal"); |
---|
2097 | 2136 | rough2.addMouseListener(new MouseAdapter() |
---|
2098 | 2137 | { |
---|
.. | .. |
---|
2110 | 2149 | }); |
---|
2111 | 2150 | presetpanel.add(rough2); |
---|
2112 | 2151 | |
---|
2113 | | - cLabel shini0 = GetLabel("icons/shadericons/shadericon00014.png", !Grafreed.NIMBUSLAF); |
---|
| 2152 | + cLabel shini0 = GetLabel("icons/shadericons/shadericon00014.png", !Globals.NIMBUSLAF); |
---|
2114 | 2153 | shini0.setToolTipText("Shiny"); |
---|
2115 | 2154 | shini0.addMouseListener(new MouseAdapter() |
---|
2116 | 2155 | { |
---|
.. | .. |
---|
2128 | 2167 | }); |
---|
2129 | 2168 | presetpanel.add(shini0); |
---|
2130 | 2169 | |
---|
2131 | | - cLabel shini1 = GetLabel("icons/shadericons/shadericon00011.png", !Grafreed.NIMBUSLAF); |
---|
| 2170 | + cLabel shini1 = GetLabel("icons/shadericons/shadericon00011.png", !Globals.NIMBUSLAF); |
---|
2132 | 2171 | shini1.setToolTipText("Shiny2"); |
---|
2133 | 2172 | shini1.addMouseListener(new MouseAdapter() |
---|
2134 | 2173 | { |
---|
.. | .. |
---|
2146 | 2185 | }); |
---|
2147 | 2186 | presetpanel.add(shini1); |
---|
2148 | 2187 | |
---|
2149 | | - cLabel shini2 = GetLabel("icons/shadericons/shadericon00012.png", !Grafreed.NIMBUSLAF); |
---|
| 2188 | + cLabel shini2 = GetLabel("icons/shadericons/shadericon00012.png", !Globals.NIMBUSLAF); |
---|
2150 | 2189 | shini2.setToolTipText("Shiny3"); |
---|
2151 | 2190 | shini2.addMouseListener(new MouseAdapter() |
---|
2152 | 2191 | { |
---|
.. | .. |
---|
2164 | 2203 | }); |
---|
2165 | 2204 | presetpanel.add(shini2); |
---|
2166 | 2205 | |
---|
2167 | | - cLabel aniso = GetLabel("icons/shadericons/shadericon00008.png", !Grafreed.NIMBUSLAF); |
---|
| 2206 | + cLabel aniso = GetLabel("icons/shadericons/shadericon00008.png", !Globals.NIMBUSLAF); |
---|
2168 | 2207 | aniso.setToolTipText("AnisoU"); |
---|
2169 | 2208 | aniso.addMouseListener(new MouseAdapter() |
---|
2170 | 2209 | { |
---|
.. | .. |
---|
2182 | 2221 | }); |
---|
2183 | 2222 | presetpanel.add(aniso); |
---|
2184 | 2223 | |
---|
2185 | | - cLabel aniso2 = GetLabel("icons/shadericons/shadericon00009.png", !Grafreed.NIMBUSLAF); |
---|
| 2224 | + cLabel aniso2 = GetLabel("icons/shadericons/shadericon00009.png", !Globals.NIMBUSLAF); |
---|
2186 | 2225 | aniso2.setToolTipText("AnisoV"); |
---|
2187 | 2226 | aniso2.addMouseListener(new MouseAdapter() |
---|
2188 | 2227 | { |
---|
.. | .. |
---|
2200 | 2239 | }); |
---|
2201 | 2240 | presetpanel.add(aniso2); |
---|
2202 | 2241 | |
---|
2203 | | - cLabel aniso3 = GetLabel("icons/shadericons/shadericon00010.png", !Grafreed.NIMBUSLAF); |
---|
| 2242 | + cLabel aniso3 = GetLabel("icons/shadericons/shadericon00010.png", !Globals.NIMBUSLAF); |
---|
2204 | 2243 | aniso3.setToolTipText("AnisoUV"); |
---|
2205 | 2244 | aniso3.addMouseListener(new MouseAdapter() |
---|
2206 | 2245 | { |
---|
.. | .. |
---|
2218 | 2257 | }); |
---|
2219 | 2258 | presetpanel.add(aniso3); |
---|
2220 | 2259 | |
---|
2221 | | - cLabel velvet0 = GetLabel("icons/shadericons/shadericon00015.png", !Grafreed.NIMBUSLAF); |
---|
| 2260 | + cLabel velvet0 = GetLabel("icons/shadericons/shadericon00015.png", !Globals.NIMBUSLAF); |
---|
2222 | 2261 | velvet0.setToolTipText("Velvet"); |
---|
2223 | 2262 | velvet0.addMouseListener(new MouseAdapter() |
---|
2224 | 2263 | { |
---|
.. | .. |
---|
2240 | 2279 | }); |
---|
2241 | 2280 | presetpanel.add(velvet0); |
---|
2242 | 2281 | |
---|
2243 | | - cLabel bump0 = GetLabel("icons/shadericons/shadericon00016.png", !Grafreed.NIMBUSLAF); |
---|
| 2282 | + cLabel bump0 = GetLabel("icons/shadericons/shadericon00016.png", !Globals.NIMBUSLAF); |
---|
2244 | 2283 | bump0.setToolTipText("Bump texture"); |
---|
2245 | 2284 | bump0.addMouseListener(new MouseAdapter() |
---|
2246 | 2285 | { |
---|
.. | .. |
---|
2259 | 2298 | }); |
---|
2260 | 2299 | presetpanel.add(bump0); |
---|
2261 | 2300 | |
---|
2262 | | - cLabel borderShader = GetLabel("icons/shadericons/borderfade.jpg", !Grafreed.NIMBUSLAF); |
---|
| 2301 | + cLabel borderShader = GetLabel("icons/shadericons/borderfade.jpg", !Globals.NIMBUSLAF); |
---|
2263 | 2302 | borderShader.setToolTipText("Border fade"); |
---|
2264 | 2303 | borderShader.addMouseListener(new MouseAdapter() |
---|
2265 | 2304 | { |
---|
.. | .. |
---|
2274 | 2313 | }); |
---|
2275 | 2314 | presetpanel.add(borderShader); |
---|
2276 | 2315 | |
---|
2277 | | - cLabel halo = GetLabel("icons/shadericons/shadericon00017.png", !Grafreed.NIMBUSLAF); |
---|
| 2316 | + cLabel halo = GetLabel("icons/shadericons/shadericon00017.png", !Globals.NIMBUSLAF); |
---|
2278 | 2317 | halo.setToolTipText("Halo"); |
---|
2279 | 2318 | halo.addMouseListener(new MouseAdapter() |
---|
2280 | 2319 | { |
---|
.. | .. |
---|
2291 | 2330 | }); |
---|
2292 | 2331 | presetpanel.add(halo); |
---|
2293 | 2332 | |
---|
2294 | | - cLabel candle = GetLabel("icons/shadericons/shadericon00018.png", !Grafreed.NIMBUSLAF); |
---|
| 2333 | + cLabel candle = GetLabel("icons/shadericons/shadericon00018.png", !Globals.NIMBUSLAF); |
---|
2295 | 2334 | candle.setToolTipText("Candle"); |
---|
2296 | 2335 | candle.addMouseListener(new MouseAdapter() |
---|
2297 | 2336 | { |
---|
.. | .. |
---|
2313 | 2352 | }); |
---|
2314 | 2353 | presetpanel.add(candle); |
---|
2315 | 2354 | |
---|
2316 | | - cLabel shadowShader = GetLabel("icons/shadericons/shadow.png", !Grafreed.NIMBUSLAF); |
---|
| 2355 | + cLabel shadowShader = GetLabel("icons/shadericons/shadow.png", !Globals.NIMBUSLAF); |
---|
2317 | 2356 | shadowShader.setToolTipText("Shadow"); |
---|
2318 | 2357 | shadowShader.addMouseListener(new MouseAdapter() |
---|
2319 | 2358 | { |
---|
.. | .. |
---|
2348 | 2387 | |
---|
2349 | 2388 | cGridBag editBar = new cGridBag().setVertical(false); |
---|
2350 | 2389 | |
---|
2351 | | - editBar.add(createMaterialButton = new cButton("Create", !Grafreed.NIMBUSLAF)); // , aConstraints); |
---|
| 2390 | + editBar.add(createMaterialButton = new cButton("Create", !Globals.NIMBUSLAF)); // , aConstraints); |
---|
2352 | 2391 | createMaterialButton.setToolTipText("Create material"); |
---|
2353 | 2392 | |
---|
2354 | 2393 | /* |
---|
2355 | 2394 | ctrlPanel.add(resetSlidersButton = new cButton("Reset All"), aConstraints); |
---|
2356 | 2395 | */ |
---|
2357 | 2396 | |
---|
2358 | | - editBar.add(clearMaterialButton = new cButton("Clear", !Grafreed.NIMBUSLAF)); // , aConstraints); |
---|
| 2397 | + editBar.add(clearMaterialButton = new cButton("Clear", !Globals.NIMBUSLAF)); // , aConstraints); |
---|
2359 | 2398 | clearMaterialButton.setToolTipText("Clear material"); |
---|
2360 | 2399 | |
---|
2361 | 2400 | if (Globals.ADVANCED) |
---|
2362 | 2401 | { |
---|
2363 | | - editBar.add(resetSlidersButton = new cButton("Reset", !Grafreed.NIMBUSLAF)); // , aConstraints); |
---|
| 2402 | + editBar.add(resetSlidersButton = new cButton("Reset", !Globals.NIMBUSLAF)); // , aConstraints); |
---|
2364 | 2403 | editBar.add(propagateToggle = new cCheckBox("Prop", propagate)); // , aConstraints); |
---|
2365 | 2404 | editBar.add(multiplyToggle = new cCheckBox("Mult", false)); // , aConstraints); |
---|
2366 | 2405 | } |
---|
.. | .. |
---|
4161 | 4200 | |
---|
4162 | 4201 | void New() |
---|
4163 | 4202 | { |
---|
4164 | | - while (copy.Size() > 1) |
---|
| 4203 | + while (copy.Size() > 0) |
---|
4165 | 4204 | { |
---|
4166 | | - copy.remove(1); |
---|
| 4205 | + copy.remove(0); |
---|
4167 | 4206 | } |
---|
4168 | 4207 | |
---|
| 4208 | + copy.selection.clear(); |
---|
| 4209 | + |
---|
| 4210 | + if (copy == Grafreed.grafreed.universe) |
---|
| 4211 | + { |
---|
| 4212 | + CreateCameras(); |
---|
| 4213 | + cameraView.SetCamera(GetCamera(copy, 0)); |
---|
| 4214 | + } |
---|
4169 | 4215 | ResetModel(); |
---|
4170 | 4216 | objEditor.refreshContents(); |
---|
4171 | 4217 | } |
---|