Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
CIRCLE
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
94
Merge Requests
10
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
7a77678d
authored
Feb 21, 2013
by
tarokkk
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
laborgui: Fixed error message
parent
2bd43c4c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
14 deletions
+8
-14
miscellaneous/laborclient/cloudgui/rdp.py
+7
-13
miscellaneous/laborclient/setup.py
+1
-1
No files found.
miscellaneous/laborclient/cloudgui/rdp.py
View file @
7a77678d
...
...
@@ -27,6 +27,7 @@ class RDP:
# window.set_title("Message dialogs")
md
=
gtk
.
MessageDialog
(
parent
=
None
,
type
=
gtk
.
MESSAGE_INFO
,
buttons
=
gtk
.
BUTTONS_CLOSE
,
message_format
=
text
)
md
.
run
()
print
"After run"
md
.
destroy
()
def
connect
(
self
):
...
...
@@ -45,6 +46,7 @@ class RDP:
#p.terminate()
if
self
.
global_vars
.
pid
>
0
:
os
.
kill
(
self
.
global_vars
.
pid
,
signal
.
SIGKILL
)
#print "Join"
p
.
join
()
elif
self
.
scheme
==
"nx"
:
self
.
connect_nx
()
...
...
@@ -72,19 +74,11 @@ class RDP:
def
connect_rdp
(
self
,
global_vars
):
rdp_command
=
[
"rdesktop"
,
"-khu"
,
"-E"
,
"-P"
,
"-0"
,
"-f"
,
"-u"
,
self
.
username
,
"-p"
,
self
.
password
,
self
.
host
+
":"
+
self
.
port
]
try
:
proc
=
subprocess
.
Popen
(
rdp_command
,
stdout
=
subprocess
.
PIPE
)
global_vars
.
pid
=
proc
.
pid
proc
.
wait
()
except
subprocess
.
CalledProcessError
as
e
:
if
e
.
returncode
!=
1
:
print
e
self
.
dialog_box
(
"Unable to connect to host: "
+
self
.
host
+
" at port "
+
self
.
port
)
finally
:
#print "Finally: "
#print self.box
global_vars
.
pid
=
0
self
.
box
.
response
(
-
5
)
proc
=
subprocess
.
Popen
(
rdp_command
,
stdout
=
subprocess
.
PIPE
)
global_vars
.
pid
=
proc
.
pid
proc
.
wait
()
self
.
box
.
response
(
-
5
)
global_vars
.
pid
=
0
def
connect_nx
(
self
):
#Generate temproary config
...
...
miscellaneous/laborclient/setup.py
View file @
7a77678d
from
setuptools
import
setup
,
find_packages
setup
(
name
=
"CloudGUI"
,
version
=
"0.
1
"
,
version
=
"0.
2
"
,
packages
=
[
'cloudgui'
,],
scripts
=
[
'cloud'
,
'rdp'
,],
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment