| .. | .. | 
|---|
| 296 | 296 |          client = inClient; | 
|---|
| 297 | 297 |          copy = client; | 
|---|
| 298 | 298 |   | 
|---|
| 299 |  | -        if (copy.versions == null)  | 
|---|
 | 299 | +        if (copy.versionlist == null)  | 
|---|
| 300 | 300 |          { | 
|---|
| 301 |  | -            copy.versions = new Object3D[100];  | 
|---|
 | 301 | +            copy.versionlist = new Object3D[100];  | 
|---|
| 302 | 302 |              copy.versionindex = -1; | 
|---|
| 303 | 303 |          } | 
|---|
| 304 | 304 |           | 
|---|
| .. | .. | 
|---|
| 315 | 315 |          client = inClient; | 
|---|
| 316 | 316 |          copy = client; | 
|---|
| 317 | 317 |   | 
|---|
| 318 |  | -        if (copy.versions == null)  | 
|---|
 | 318 | +        if (copy.versionlist == null)  | 
|---|
| 319 | 319 |          { | 
|---|
| 320 |  | -            copy.versions = new Object3D[100];  | 
|---|
 | 320 | +            copy.versionlist = new Object3D[100];  | 
|---|
| 321 | 321 |              copy.versionindex = -1; | 
|---|
| 322 | 322 |          } | 
|---|
| 323 | 323 |           | 
|---|
| .. | .. | 
|---|
| 353 | 353 |          copy = localCopy; | 
|---|
| 354 | 354 |          copy.editWindow = this; | 
|---|
| 355 | 355 |   | 
|---|
| 356 |  | -        if (copy.versions == null)  | 
|---|
 | 356 | +        if (copy.versionlist == null)  | 
|---|
| 357 | 357 |          { | 
|---|
| 358 | 358 |  //            copy.versions = new byte[100][]; | 
|---|
| 359 | 359 |  //            copy.versionindex = -1; | 
|---|
| .. | .. | 
|---|
| 467 | 467 |          toolboxPanel = new cGridBag().setVertical(true); | 
|---|
| 468 | 468 |          //toolboxPanel.setName("Toolbox"); | 
|---|
| 469 | 469 |           | 
|---|
| 470 |  | -        materialPanel = new cGridBag().setVertical(true);  | 
|---|
 | 470 | +        materialPanel = new cGridBag().setVertical(false);  | 
|---|
| 471 | 471 |          //materialPanel.setName("Material"); | 
|---|
| 472 | 472 |           | 
|---|
| 473 | 473 |          /*JTextPane*/ | 
|---|
| .. | .. | 
|---|
| 858 | 858 |          copy.ExtractBigData(versiontable); | 
|---|
| 859 | 859 |          // if (copy == client) | 
|---|
| 860 | 860 |           | 
|---|
| 861 |  | -        Object3D versions[] = copy.versions;  | 
|---|
| 862 |  | -        copy.versions = null;  | 
|---|
 | 861 | +        Object3D versions[] = copy.versionlist;  | 
|---|
 | 862 | +        copy.versionlist = null;  | 
|---|
| 863 | 863 |           | 
|---|
| 864 | 864 |          //byte[] compress = Compress(copy); | 
|---|
| 865 | 865 |          Object3D compress = (Object3D)Grafreed.clone(copy); | 
|---|
| 866 | 866 |           | 
|---|
| 867 |  | -        copy.versions = versions;  | 
|---|
 | 867 | +        copy.versionlist = versions;  | 
|---|
| 868 | 868 |           | 
|---|
| 869 | 869 |          copy.RestoreBigData(versiontable); | 
|---|
| 870 | 870 |           | 
|---|
| .. | .. | 
|---|
| 994 | 994 |          { | 
|---|
| 995 | 995 |              SetupMaterial(materialPanel); | 
|---|
| 996 | 996 |          } | 
|---|
 | 997 | +          | 
|---|
| 997 | 998 |          //SetupName(); | 
|---|
| 998 | 999 |          //SetupViews(); | 
|---|
| 999 | 1000 |      } | 
|---|
| .. | .. | 
|---|
| 1551 | 1552 |          //tmp.setName("Edit"); | 
|---|
| 1552 | 1553 |          objectPanel.add(materialPanel); | 
|---|
| 1553 | 1554 |          objectPanel.setIconAt(0, GetIcon("icons/material.png")); | 
|---|
| 1554 |  | -        objectPanel.setToolTipTextAt(0, "Material panel");  | 
|---|
 | 1555 | +        objectPanel.setToolTipTextAt(0, "Material");  | 
|---|
| 1555 | 1556 |       | 
|---|
| 1556 | 1557 |  //        JPanel north = new JPanel(new BorderLayout()); | 
|---|
| 1557 | 1558 |  //        north.setName("Edit"); | 
|---|
| .. | .. | 
|---|
| 1559 | 1560 |  //        objectPanel.add(north); | 
|---|
| 1560 | 1561 |          objectPanel.add(editPanel); | 
|---|
| 1561 | 1562 |          objectPanel.setIconAt(1, GetIcon("icons/write.png")); | 
|---|
| 1562 |  | -        objectPanel.setToolTipTextAt(1, "Edit panel");  | 
|---|
 | 1563 | +        objectPanel.setToolTipTextAt(1, "Edit controls");  | 
|---|
| 1563 | 1564 |           | 
|---|
| 1564 | 1565 |          //if (Globals.ADVANCED) | 
|---|
| 1565 | 1566 |              objectPanel.add(infoPanel); | 
|---|
| 1566 | 1567 |          objectPanel.setIconAt(2, GetIcon("icons/info.png")); | 
|---|
| 1567 |  | -        objectPanel.setToolTipTextAt(2, "Info panel");  | 
|---|
 | 1568 | +        objectPanel.setToolTipTextAt(2, "Information");  | 
|---|
| 1568 | 1569 |           | 
|---|
| 1569 | 1570 |          objectPanel.add(XYZPanel); | 
|---|
| 1570 | 1571 |          objectPanel.setIconAt(3, GetIcon("icons/XYZ.png")); | 
|---|
| 1571 |  | -        objectPanel.setToolTipTextAt(3, "XYZ/RGB panel");  | 
|---|
 | 1572 | +        objectPanel.setToolTipTextAt(3, "XYZ/RGB transform");  | 
|---|
| 1572 | 1573 |           | 
|---|
| 1573 | 1574 |          objectPanel.add(toolboxPanel); | 
|---|
| 1574 | 1575 |          objectPanel.setIconAt(4, GetIcon("icons/primitives.png")); | 
|---|
| 1575 |  | -        objectPanel.setToolTipTextAt(4, "Objects/backgrounds panel");  | 
|---|
 | 1576 | +        objectPanel.setToolTipTextAt(4, "Objects & backgrounds");  | 
|---|
| 1576 | 1577 |   | 
|---|
| 1577 | 1578 |          /* | 
|---|
| 1578 | 1579 |          aConstraints.gridx = 0; | 
|---|
| .. | .. | 
|---|
| 1734 | 1735 |          ctrlPanel.removeAll(); | 
|---|
| 1735 | 1736 |      } | 
|---|
| 1736 | 1737 |   | 
|---|
| 1737 |  | -    void SetupMaterial(cGridBag panel)  | 
|---|
 | 1738 | +    void SetupMaterial(cGridBag materialpanel)  | 
|---|
| 1738 | 1739 |      { | 
|---|
| 1739 |  | -         /*  | 
|---|
 | 1740 | +        cGridBag presetpanel = new cGridBag().setVertical(true);  | 
|---|
 | 1741 | +        cLabel label = GetLabel("icons/shadericons/shadericon00000.png", !Grafreed.NIMBUSLAF);  | 
|---|
 | 1742 | +        label.addMouseListener(new MouseAdapter()  | 
|---|
 | 1743 | +        {  | 
|---|
 | 1744 | +            public void mouseClicked(MouseEvent e)  | 
|---|
 | 1745 | +            {  | 
|---|
 | 1746 | +                colorField.setFloat(0);  | 
|---|
 | 1747 | +                saturationField.setFloat(1);  | 
|---|
 | 1748 | +                materialtouched = true;  | 
|---|
 | 1749 | +                applySelf();  | 
|---|
 | 1750 | +            }  | 
|---|
 | 1751 | +        });  | 
|---|
 | 1752 | +        presetpanel.add(label);  | 
|---|
 | 1753 | +          | 
|---|
 | 1754 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00001.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1755 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00002.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1756 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00003.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1757 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00004.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1758 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00005.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1759 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00006.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1760 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00007.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1761 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00008.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1762 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00009.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1763 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00010.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1764 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00011.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1765 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00012.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1766 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00013.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1767 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00014.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1768 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00015.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1769 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00016.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1770 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00017.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1771 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00018.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1772 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00019.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1773 | +        presetpanel.add(GetLabel("icons/shadericons/shadericon00020.png", !Grafreed.NIMBUSLAF));  | 
|---|
 | 1774 | +          | 
|---|
 | 1775 | +        cGridBag panel = new cGridBag().setVertical(true);  | 
|---|
 | 1776 | +          | 
|---|
 | 1777 | +        presetpanel.preferredWidth = 1;  | 
|---|
 | 1778 | +          | 
|---|
 | 1779 | +        materialpanel.add(panel);  | 
|---|
 | 1780 | +        materialpanel.add(presetpanel);  | 
|---|
 | 1781 | +          | 
|---|
 | 1782 | +        panel.preferredWidth = 8;  | 
|---|
 | 1783 | +          | 
|---|
 | 1784 | +        /*  | 
|---|
| 1740 | 1785 |          ctrlPanel.add(materialLabel = new JLabel("MATERIAL : "), aConstraints); | 
|---|
| 1741 | 1786 |          materialLabel.setHorizontalAlignment(SwingConstants.TRAILING); | 
|---|
| 1742 |  | -         */  | 
|---|
 | 1787 | +        */  | 
|---|
| 1743 | 1788 |   | 
|---|
| 1744 | 1789 |          cGridBag editBar = new cGridBag().setVertical(false); | 
|---|
| 1745 | 1790 |               | 
|---|
| .. | .. | 
|---|
| 1776 | 1821 |   | 
|---|
| 1777 | 1822 |          cGridBag huepanel = new cGridBag(); | 
|---|
| 1778 | 1823 |              cGridBag huelabel = new cGridBag(); | 
|---|
| 1779 |  | -            huelabel.add(GetLabel("icons/hue.png", false));  | 
|---|
 | 1824 | +        label = GetLabel("icons/hue.png", false);  | 
|---|
 | 1825 | +        label.fit = true;  | 
|---|
 | 1826 | +            huelabel.add(label);  | 
|---|
| 1780 | 1827 |              huelabel.preferredWidth = 20; | 
|---|
| 1781 | 1828 |              huepanel.add(new cGridBag()); // Label | 
|---|
| 1782 | 1829 |              huepanel.add(huelabel); // Field/slider | 
|---|
| .. | .. | 
|---|
| 1797 | 1844 |          cGridBag modulation = new cGridBag(); | 
|---|
| 1798 | 1845 |                  modulation.add(modulationLabel = new JLabel("Saturation")); // , aConstraints); | 
|---|
| 1799 | 1846 |                  modulationLabel.setHorizontalAlignment(SwingConstants.TRAILING); | 
|---|
| 1800 |  | -                modulation.add(modulationField = new cNumberSlider(this, 0.001, 1)); // , aConstraints);  | 
|---|
 | 1847 | +                modulation.add(saturationField = new cNumberSlider(this, 0.001, 1)); // , aConstraints);  | 
|---|
| 1801 | 1848 |          colorSection.add(modulation); | 
|---|
| 1802 | 1849 |   | 
|---|
| 1803 | 1850 |          cGridBag opacity = new cGridBag(); | 
|---|
| .. | .. | 
|---|
| 2990 | 3037 |   | 
|---|
| 2991 | 3038 |          freezematerial = true; | 
|---|
| 2992 | 3039 |          colorField.setFloat(mat.color); | 
|---|
| 2993 |  | -        modulationField.setFloat(mat.modulation);  | 
|---|
 | 3040 | +        saturationField.setFloat(mat.modulation);  | 
|---|
| 2994 | 3041 |          metalnessField.setFloat(mat.metalness); | 
|---|
| 2995 | 3042 |          diffuseField.setFloat(mat.diffuse); | 
|---|
| 2996 | 3043 |          specularField.setFloat(mat.specular); | 
|---|
| .. | .. | 
|---|
| 3301 | 3348 |          } else if (event.getSource() == liveCB) | 
|---|
| 3302 | 3349 |          { | 
|---|
| 3303 | 3350 |              copy.live ^= true; | 
|---|
 | 3351 | +            objEditor.refreshContents(true); // To show item colors  | 
|---|
| 3304 | 3352 |              return; | 
|---|
| 3305 | 3353 |          } else if (event.getSource() == selectableCB) | 
|---|
| 3306 | 3354 |          { | 
|---|
| .. | .. | 
|---|
| 3310 | 3358 |          { | 
|---|
| 3311 | 3359 |              copy.hide ^= true; | 
|---|
| 3312 | 3360 |              copy.Touch(); // display list issue | 
|---|
| 3313 |  | -            objEditor.refreshContents();  | 
|---|
 | 3361 | +            objEditor.refreshContents(true); // To show item colors  | 
|---|
| 3314 | 3362 |              return; | 
|---|
| 3315 | 3363 |          } else if (event.getSource() == link2masterCB) | 
|---|
| 3316 | 3364 |          { | 
|---|
| .. | .. | 
|---|
| 3668 | 3716 |      { | 
|---|
| 3669 | 3717 |          //Save(true); | 
|---|
| 3670 | 3718 |          Replace(); | 
|---|
 | 3719 | +        SetUndoStates();  | 
|---|
| 3671 | 3720 |      } | 
|---|
| 3672 | 3721 |       | 
|---|
| 3673 | 3722 |      private boolean Equal(byte[] compress, byte[] name) | 
|---|
| .. | .. | 
|---|
| 3691 | 3740 |      public boolean Save(boolean user) | 
|---|
| 3692 | 3741 |      { | 
|---|
| 3693 | 3742 |          System.err.println("Save"); | 
|---|
 | 3743 | +        Replace();  | 
|---|
| 3694 | 3744 |           | 
|---|
| 3695 | 3745 |          cRadio tab = GetCurrentTab(); | 
|---|
| 3696 | 3746 |           | 
|---|
| .. | .. | 
|---|
| 3709 | 3759 |              //tab.user[tab.versionindex] = user; | 
|---|
| 3710 | 3760 |              //boolean increment = true; // tab.graphs[tab.versionindex] == null; | 
|---|
| 3711 | 3761 |               | 
|---|
| 3712 |  | -            copy.versions[++copy.versionindex] = compress;  | 
|---|
 | 3762 | +            copy.versionlist[++copy.versionindex] = compress;  | 
|---|
| 3713 | 3763 |               | 
|---|
| 3714 | 3764 |              // if (increment) | 
|---|
| 3715 | 3765 |              //     tab.versionindex++; | 
|---|
| .. | .. | 
|---|
| 3719 | 3769 |   | 
|---|
| 3720 | 3770 |          //assert(hashtable.isEmpty()); | 
|---|
| 3721 | 3771 |           | 
|---|
| 3722 |  | -        for (int i = copy.versionindex+1; i < copy.versions.length; i++)  | 
|---|
 | 3772 | +        for (int i = copy.versionindex+1; i < copy.versionlist.length; i++)  | 
|---|
| 3723 | 3773 |          { | 
|---|
| 3724 | 3774 |              //tab.user[i] = false; | 
|---|
| 3725 |  | -            copy.versions[i] = null;  | 
|---|
 | 3775 | +            copy.versionlist[i] = null;  | 
|---|
| 3726 | 3776 |          } | 
|---|
| 3727 | 3777 |   | 
|---|
| 3728 | 3778 |          SetUndoStates(); | 
|---|
| .. | .. | 
|---|
| 3748 | 3798 |           | 
|---|
| 3749 | 3799 |          return !thesame; | 
|---|
| 3750 | 3800 |      } | 
|---|
 | 3801 | +      | 
|---|
 | 3802 | +    boolean flashIt = true;  | 
|---|
 | 3803 | +          | 
|---|
 | 3804 | +    void RefreshSelection()  | 
|---|
 | 3805 | +    {  | 
|---|
 | 3806 | +        Object3D selection = new Object3D();  | 
|---|
 | 3807 | +          | 
|---|
 | 3808 | +        for (int i = 0; i < copy.selection.size(); i++)  | 
|---|
 | 3809 | +        {  | 
|---|
 | 3810 | +            Object3D elem = copy.selection.elementAt(i);  | 
|---|
 | 3811 | +              | 
|---|
 | 3812 | +            Object3D obj = copy.GetObject(elem.GetUUID());  | 
|---|
 | 3813 | +              | 
|---|
 | 3814 | +            if (obj == null)  | 
|---|
 | 3815 | +            {  | 
|---|
 | 3816 | +                copy.selection.remove(i--);  | 
|---|
 | 3817 | +            }  | 
|---|
 | 3818 | +            else  | 
|---|
 | 3819 | +            {  | 
|---|
 | 3820 | +                selection.add(obj);  | 
|---|
 | 3821 | +                copy.selection.setElementAt(obj, i);  | 
|---|
 | 3822 | +            }  | 
|---|
 | 3823 | +        }  | 
|---|
 | 3824 | +          | 
|---|
 | 3825 | +        flashIt = false;          | 
|---|
 | 3826 | +        GetTree().clearSelection();  | 
|---|
 | 3827 | +        for (int i = 0; i < selection.size(); i++)  | 
|---|
 | 3828 | +            GetTree().addSelectionPath(selection.elementAt(i).GetTreePath().GetTreePath());  | 
|---|
 | 3829 | +        flashIt = true;  | 
|---|
 | 3830 | +          | 
|---|
 | 3831 | +        refreshContents(false);  | 
|---|
 | 3832 | +    }  | 
|---|
| 3751 | 3833 |   | 
|---|
| 3752 | 3834 |      void CopyChanged(Object3D obj) | 
|---|
| 3753 | 3835 |      { | 
|---|
| .. | .. | 
|---|
| 3772 | 3854 |           | 
|---|
| 3773 | 3855 |          CameraPane.SWITCH = temp; | 
|---|
| 3774 | 3856 |           | 
|---|
 | 3857 | +        RefreshSelection();  | 
|---|
| 3775 | 3858 |          //assert(hashtable.isEmpty()); | 
|---|
| 3776 | 3859 |           | 
|---|
| 3777 | 3860 |          copy.Touch(); | 
|---|
| .. | .. | 
|---|
| 3806 | 3889 |      { | 
|---|
| 3807 | 3890 |          int count = 0; | 
|---|
| 3808 | 3891 |           | 
|---|
| 3809 |  | -        for (int i = copy.versions.length; --i >= 0;)  | 
|---|
 | 3892 | +        for (int i = copy.versionlist.length; --i >= 0;)  | 
|---|
| 3810 | 3893 |          { | 
|---|
| 3811 |  | -            if (copy.versions[i] != null)  | 
|---|
 | 3894 | +            if (copy.versionlist[i] != null)  | 
|---|
| 3812 | 3895 |                  count++; | 
|---|
| 3813 | 3896 |          } | 
|---|
| 3814 | 3897 |           | 
|---|
| .. | .. | 
|---|
| 3823 | 3906 |          replaceButton.setEnabled(copy.versionindex != -1); | 
|---|
| 3824 | 3907 |           | 
|---|
| 3825 | 3908 |          undoButton.setEnabled(copy.versionindex > 0); | 
|---|
| 3826 |  | -        redoButton.setEnabled(copy.versions[copy.versionindex + 1] != null);  | 
|---|
 | 3909 | +        redoButton.setEnabled(copy.versionlist[copy.versionindex + 1] != null);  | 
|---|
| 3827 | 3910 |           | 
|---|
| 3828 | 3911 |          muteSlider = true; | 
|---|
| 3829 | 3912 |          versionSlider.setMaximum(VersionCount() - 1); | 
|---|
| .. | .. | 
|---|
| 3861 | 3944 |   | 
|---|
| 3862 | 3945 |          copy.versionindex -= 1; | 
|---|
| 3863 | 3946 |   | 
|---|
| 3864 |  | -        CopyChanged((Object3D)copy.versions[copy.versionindex]);  | 
|---|
 | 3947 | +        CopyChanged((Object3D)copy.versionlist[copy.versionindex]);  | 
|---|
| 3865 | 3948 |           | 
|---|
| 3866 | 3949 |          return true; | 
|---|
| 3867 | 3950 |      } | 
|---|
| .. | .. | 
|---|
| 3872 | 3955 |           | 
|---|
| 3873 | 3956 |          cRadio tab = GetCurrentTab(); | 
|---|
| 3874 | 3957 |           | 
|---|
| 3875 |  | -        if (copy.versionindex == -1 || copy.versions[copy.versionindex] == null)  | 
|---|
 | 3958 | +        if (copy.versionindex == -1 || copy.versionlist[copy.versionindex] == null)  | 
|---|
| 3876 | 3959 |          { | 
|---|
| 3877 | 3960 |              java.awt.Toolkit.getDefaultToolkit().beep(); | 
|---|
| 3878 | 3961 |              return false; | 
|---|
| 3879 | 3962 |          } | 
|---|
| 3880 | 3963 |   | 
|---|
| 3881 | 3964 |          //CopyChanged((Object3D)Uncompress(copy.versions[copy.versionindex])); | 
|---|
| 3882 |  | -        CopyChanged(copy.versions[copy.versionindex]);  | 
|---|
 | 3965 | +        CopyChanged(copy.versionlist[copy.versionindex]);  | 
|---|
| 3883 | 3966 |           | 
|---|
| 3884 | 3967 |          return true; | 
|---|
| 3885 | 3968 |      } | 
|---|
| .. | .. | 
|---|
| 3890 | 3973 |           | 
|---|
| 3891 | 3974 |          cRadio tab = GetCurrentTab(); | 
|---|
| 3892 | 3975 |           | 
|---|
| 3893 |  | -        if (copy.versionindex == -1 || copy.versions[copy.versionindex] == null)  | 
|---|
 | 3976 | +        if (copy.versionindex == -1 || copy.versionlist[copy.versionindex] == null)  | 
|---|
| 3894 | 3977 |          { | 
|---|
| 3895 | 3978 |              // No version yet. OK. java.awt.Toolkit.getDefaultToolkit().beep(); | 
|---|
| 3896 | 3979 |              return false; | 
|---|
| 3897 | 3980 |          } | 
|---|
| 3898 | 3981 |   | 
|---|
| 3899 |  | -        copy.versions[copy.versionindex] = CompressCopy();  | 
|---|
 | 3982 | +        copy.versionlist[copy.versionindex] = CompressCopy();  | 
|---|
| 3900 | 3983 |           | 
|---|
| 3901 | 3984 |          return true; | 
|---|
| 3902 | 3985 |      } | 
|---|
| .. | .. | 
|---|
| 3908 | 3991 |           | 
|---|
| 3909 | 3992 |          cRadio tab = GetCurrentTab(); | 
|---|
| 3910 | 3993 |           | 
|---|
| 3911 |  | -        if (copy.versions[copy.versionindex + 1] == null)  | 
|---|
 | 3994 | +        if (copy.versionlist[copy.versionindex + 1] == null)  | 
|---|
| 3912 | 3995 |          { | 
|---|
| 3913 | 3996 |              java.awt.Toolkit.getDefaultToolkit().beep(); | 
|---|
| 3914 | 3997 |              return; | 
|---|
| .. | .. | 
|---|
| 3916 | 3999 |   | 
|---|
| 3917 | 4000 |          copy.versionindex += 1; | 
|---|
| 3918 | 4001 |   | 
|---|
| 3919 |  | -        CopyChanged(copy.versions[copy.versionindex]);  | 
|---|
 | 4002 | +        CopyChanged(copy.versionlist[copy.versionindex]);  | 
|---|
| 3920 | 4003 |           | 
|---|
| 3921 | 4004 |          //if (!tab.user[tab.versionindex]) | 
|---|
| 3922 | 4005 |          //    tab.graphs[tab.versionindex] = null; | 
|---|
| .. | .. | 
|---|
| 4130 | 4213 |              //copy.material = new cMaterial(copy.GetMaterial()); | 
|---|
| 4131 | 4214 |   | 
|---|
| 4132 | 4215 |              current.color = (float) colorField.getFloat(); | 
|---|
| 4133 |  | -            current.modulation = (float) modulationField.getFloat();  | 
|---|
 | 4216 | +            current.modulation = (float) saturationField.getFloat();  | 
|---|
| 4134 | 4217 |              current.metalness = (float) metalnessField.getFloat(); | 
|---|
| 4135 | 4218 |              current.diffuse = (float) diffuseField.getFloat(); | 
|---|
| 4136 | 4219 |              current.specular = (float) specularField.getFloat(); | 
|---|
| .. | .. | 
|---|
| 4163 | 4246 |                      cMaterial mat = copy.material; | 
|---|
| 4164 | 4247 |                               | 
|---|
| 4165 | 4248 |                      colorField.SetToolTipValue((mat.color)); | 
|---|
| 4166 |  | -                    modulationField.SetToolTipValue((mat.modulation));  | 
|---|
 | 4249 | +                    saturationField.SetToolTipValue((mat.modulation));  | 
|---|
| 4167 | 4250 |                      metalnessField.SetToolTipValue((mat.metalness)); | 
|---|
| 4168 | 4251 |                      diffuseField.SetToolTipValue((mat.diffuse)); | 
|---|
| 4169 | 4252 |                      specularField.SetToolTipValue((mat.specular)); | 
|---|
| .. | .. | 
|---|
| 4227 | 4310 |               | 
|---|
| 4228 | 4311 |              int version = versionSlider.getInteger(); | 
|---|
| 4229 | 4312 |               | 
|---|
| 4230 |  | -            if (copy.versions[version] != null)  | 
|---|
 | 4313 | +            if (copy.versionlist[version] != null)  | 
|---|
| 4231 | 4314 |              { | 
|---|
| 4232 |  | -                CopyChanged(copy.versions[copy.versionindex = version]);  | 
|---|
 | 4315 | +                CopyChanged(copy.versionlist[copy.versionindex = version]);  | 
|---|
| 4233 | 4316 |              } | 
|---|
| 4234 | 4317 |               | 
|---|
| 4235 | 4318 |              return; | 
|---|
| .. | .. | 
|---|
| 4269 | 4352 |          { | 
|---|
| 4270 | 4353 |              //System.out.println("stateChanged = " + this); | 
|---|
| 4271 | 4354 |              materialtouched = true; | 
|---|
 | 4355 | +              | 
|---|
 | 4356 | +            if (e.getSource() == colorField && saturationField.getFloat() == 0.001)  | 
|---|
 | 4357 | +            {  | 
|---|
 | 4358 | +                saturationField.setFloat(1);  | 
|---|
 | 4359 | +            }  | 
|---|
 | 4360 | +  | 
|---|
| 4272 | 4361 |              applySelf(); | 
|---|
| 4273 | 4362 |              //System.out.println("this = " + this); | 
|---|
| 4274 | 4363 |              //System.out.println("PARENT = " + parent); | 
|---|
| .. | .. | 
|---|
| 4568 | 4657 |          { | 
|---|
| 4569 | 4658 |              if (GetTree() != null) | 
|---|
| 4570 | 4659 |              { | 
|---|
 | 4660 | +                GetTree().revalidate();  | 
|---|
| 4571 | 4661 |                  GetTree().repaint(); | 
|---|
| 4572 | 4662 |              } | 
|---|
| 4573 | 4663 |   | 
|---|
| .. | .. | 
|---|
| 4959 | 5049 |                  c.addChild(csg); | 
|---|
| 4960 | 5050 |              } | 
|---|
| 4961 | 5051 |   | 
|---|
| 4962 |  | -            copy.versions = readobj.versions;  | 
|---|
 | 5052 | +            copy.versionlist = readobj.versionlist;  | 
|---|
| 4963 | 5053 |              copy.versionindex = readobj.versionindex; | 
|---|
| 4964 | 5054 |               | 
|---|
| 4965 |  | -        if (copy.versions == null)  | 
|---|
 | 5055 | +        if (copy.versionlist == null)  | 
|---|
| 4966 | 5056 |          { | 
|---|
| 4967 |  | -            copy.versions = new Object3D[100];  | 
|---|
 | 5057 | +            copy.versionlist = new Object3D[100];  | 
|---|
| 4968 | 5058 |              copy.versionindex = -1; | 
|---|
| 4969 | 5059 |          } | 
|---|
| 4970 | 5060 |           | 
|---|
| .. | .. | 
|---|
| 5372 | 5462 |      JLabel colorLabel; | 
|---|
| 5373 | 5463 |      cNumberSlider colorField; | 
|---|
| 5374 | 5464 |      JLabel modulationLabel; | 
|---|
| 5375 |  | -    cNumberSlider modulationField;  | 
|---|
 | 5465 | +    cNumberSlider saturationField;  | 
|---|
| 5376 | 5466 |      JLabel metalnessLabel; | 
|---|
| 5377 | 5467 |      cNumberSlider metalnessField; | 
|---|
| 5378 | 5468 |      JLabel diffuseLabel; | 
|---|