155 pass |
156 pass |
156 else: |
157 else: |
157 # now do the call |
158 # now do the call |
158 from .VirtualenvExecDialog import VirtualenvExecDialog |
159 from .VirtualenvExecDialog import VirtualenvExecDialog |
159 dia = VirtualenvExecDialog(resultDict, self) |
160 dia = VirtualenvExecDialog(resultDict, self) |
160 ## dia = VirtualenvExecDialog(pyvenv, targetDir, name, openTarget, |
|
161 ## createLog, createScript, interpreter, |
|
162 ## self) |
|
163 dia.show() |
161 dia.show() |
164 dia.start(resultDict["arguments"]) |
162 dia.start(resultDict["arguments"]) |
165 dia.exec_() |
163 dia.exec_() |
166 |
164 |
167 def addVirtualEnv(self, venvName, venvDirectory, venvInterpreter="", |
165 def addVirtualEnv(self, venvName, venvDirectory, venvInterpreter="", |
201 from .VirtualenvInterpreterSelectionDialog import \ |
199 from .VirtualenvInterpreterSelectionDialog import \ |
202 VirtualenvInterpreterSelectionDialog |
200 VirtualenvInterpreterSelectionDialog |
203 dlg = VirtualenvInterpreterSelectionDialog(venvName, venvDirectory) |
201 dlg = VirtualenvInterpreterSelectionDialog(venvName, venvDirectory) |
204 if dlg.exec_() == QDialog.Accepted: |
202 if dlg.exec_() == QDialog.Accepted: |
205 venvInterpreter, venvVariant = dlg.getData() |
203 venvInterpreter, venvVariant = dlg.getData() |
206 isGlobal = True |
204 if not Utilities.startswithPath(venvInterpreter, |
|
205 venvDirectory): |
|
206 isGlobal = True |
207 |
207 |
208 if venvInterpreter: |
208 if venvInterpreter: |
209 self.__virtualEnvironments[venvName] = { |
209 self.__virtualEnvironments[venvName] = { |
210 "path": venvDirectory, |
210 "path": venvDirectory, |
211 "interpreter": venvInterpreter, |
211 "interpreter": venvInterpreter, |