~ubuntu-branches/ubuntu/trusty/monodevelop/trusty-proposed

« back to all changes in this revision

Viewing changes to src/core/MonoDevelop.Ide/MonoDevelop.Ide.Projects.OptionPanels/CommonAssemblySigningPreferences.cs

  • Committer: Package Import Robot
  • Author(s): Jo Shields
  • Date: 2013-05-12 09:46:03 UTC
  • mto: This revision was merged to the branch mainline in revision 29.
  • Revision ID: package-import@ubuntu.com-20130512094603-mad323bzcxvmcam0
Tags: upstream-4.0.5+dfsg
ImportĀ upstreamĀ versionĀ 4.0.5+dfsg

Show diffs side-by-side

added added

removed removed

Lines of Context:
49
49
                        this.configurations = configurations;
50
50
                        
51
51
                        int signAsm = -1;
 
52
                        int delaySign = -1;
52
53
                        
53
54
                        keyFile = null;
54
55
                        foreach (DotNetProjectConfiguration c in configurations) {
57
58
                                        signAsm = r;
58
59
                                else if (signAsm != r)
59
60
                                        signAsm = 2;
 
61
                                int d = c.DelaySign ? 1 : 0;
 
62
                                if (delaySign == -1)
 
63
                                        delaySign = d;
 
64
                                else if (delaySign != d)
 
65
                                        delaySign = 2;
60
66
                                if (keyFile == null)
61
67
                                        keyFile = c.AssemblyKeyFile;
62
68
                                else if (keyFile != c.AssemblyKeyFile)
69
75
                                signAssemblyCheckbutton.Inconsistent = false;
70
76
                                signAssemblyCheckbutton.Active = signAsm == 1;
71
77
                        }
 
78
                        if (delaySign == 2)
 
79
                                delaySignCheckbutton.Inconsistent = true;
 
80
                        else {
 
81
                                delaySignCheckbutton.Inconsistent = false;
 
82
                                delaySignCheckbutton.Active = delaySign == 1;
 
83
                        }
72
84
                        
73
85
                        if (keyFile == null || keyFile == "?")
74
86
                                this.strongNameFileEntry.Path = string.Empty;
83
95
                void SignAssemblyCheckbuttonActivated (object sender, EventArgs e)
84
96
                {
85
97
                        signAssemblyCheckbutton.Inconsistent = false;
86
 
                        this.strongNameFileLabel.Sensitive = this.strongNameFileEntry.Sensitive = this.signAssemblyCheckbutton.Active;
 
98
                        this.delaySignCheckbutton.Sensitive = this.strongNameFileLabel.Sensitive = this.strongNameFileEntry.Sensitive = this.signAssemblyCheckbutton.Active;
87
99
                }
88
100
                
89
101
                public void StorePanelContents ()
90
102
                {
91
103
                        foreach (DotNetProjectConfiguration c in configurations) {
92
 
                                if (!signAssemblyCheckbutton.Inconsistent)
 
104
                                if (!signAssemblyCheckbutton.Inconsistent) {
93
105
                                        c.SignAssembly = this.signAssemblyCheckbutton.Active;
 
106
                                        c.DelaySign = this.delaySignCheckbutton.Active;
 
107
                                }
94
108
                                if (strongNameFileEntry.Path.Length > 0 || keyFile != "?")
95
109
                                        c.AssemblyKeyFile = this.strongNameFileEntry.Path;
96
110
                        }
122
136
                                else {
123
137
                                        if (c.SignAssembly != cref.SignAssembly)
124
138
                                                return false;
 
139
                                        if (c.DelaySign != cref.DelaySign)
 
140
                                                return false;
125
141
                                        if (c.AssemblyKeyFile != cref.AssemblyKeyFile)
126
142
                                                return false;
127
143
                                }