mirror of
https://github.com/gryf/wicd.git
synced 2025-12-20 21:08:06 +01:00
curses/prefs_curses.py:
Finished refactoring to accommodate the ComboBox changes
curses/wicd-curses.py:
Moved some of the keybinding code around
in/other=WHEREAREMYFILES.in: ADDED.
File telling the user where the wicd config files are. Usually symlinked to
~/.wicd/WHEREAREMYFILES and installed to the documentation directory
in/scripts=wicd-client.in:
Make ~/.wicd and link WHEREAREMYFILES if it has not been done so already.
Start wicd-curses if there is no X server on this console
(determined by the presence of $DISPLAY), and add a file detailing this
man/wicd-client.1: Added note about wicd-client starting wicd-curses
setup.py: Install WHEREAREMYFILES along with the rest of the documentation
This commit is contained in:
@@ -345,7 +345,7 @@ class PrefsDialog(urwid.WidgetWrap):
|
||||
self.search_dom.get_edit_text())
|
||||
daemon.SetWirelessInterface(self.wless_edit.get_edit_text())
|
||||
daemon.SetWiredInterface(self.wired_edit.get_edit_text())
|
||||
daemon.SetWPADriver(self.wpadrivers[self.wpa_cbox.get_selected()[1]])
|
||||
daemon.SetWPADriver(self.wpadrivers[self.wpa_cbox.get_focus()[1]])
|
||||
daemon.SetAlwaysShowWiredInterface(self.always_show_wired_checkb.get_state())
|
||||
daemon.SetAutoReconnect(self.auto_reconn_checkb.get_state())
|
||||
daemon.SetDebugMode(self.debug_mode_checkb.get_state())
|
||||
@@ -357,7 +357,7 @@ class PrefsDialog(urwid.WidgetWrap):
|
||||
else:
|
||||
daemon.SetWiredAutoConnectMethod(1)
|
||||
|
||||
daemon.SetBackend(self.backends[self.backend_cbox.get_selected()[1]])
|
||||
daemon.SetBackend(self.backends[self.backend_cbox.get_focus()[1]])
|
||||
|
||||
# External Programs Tab
|
||||
if self.dhcp0.get_state():
|
||||
|
||||
@@ -576,12 +576,6 @@ class appGUI():
|
||||
self.update_ui()
|
||||
if "A" in keys:
|
||||
about_dialog(self.frame)
|
||||
for k in keys:
|
||||
if k == "window resize":
|
||||
self.size = ui.get_cols_rows()
|
||||
continue
|
||||
self.frame.keypress( self.size, k )
|
||||
|
||||
if "C" in keys:
|
||||
focus = self.thePile.get_focus()
|
||||
if focus == self.wiredCB:
|
||||
@@ -593,6 +587,12 @@ class appGUI():
|
||||
#self.netentry = NetEntryBase(dbusmanager.get_dbus_ifaces())
|
||||
#self.netentry.run(ui,self.size,self.frame)
|
||||
|
||||
for k in keys:
|
||||
if k == "window resize":
|
||||
self.size = ui.get_cols_rows()
|
||||
continue
|
||||
self.frame.keypress( self.size, k )
|
||||
|
||||
if " " in keys:
|
||||
focus = self.thePile.get_focus()
|
||||
if focus == self.wiredCB:
|
||||
|
||||
14
in/other=WHEREAREMYFILES.in
Normal file
14
in/other=WHEREAREMYFILES.in
Normal file
@@ -0,0 +1,14 @@
|
||||
If you are reading this, you are probably wondering why your Wicd configuration
|
||||
files are not here. What follows is a summary of the folders that wicd uses.
|
||||
|
||||
For a more detailed (and complete) description what is in each directory, consult the
|
||||
man pages for wicd(8) and wicd-curses(8).
|
||||
|
||||
~/.wicd
|
||||
User-dependent configuration files, only used by wicd-curses
|
||||
|
||||
%ETC%
|
||||
Global configuration files
|
||||
|
||||
%NETWORKS%
|
||||
Individual network configurations
|
||||
@@ -1,2 +1,47 @@
|
||||
#!/bin/bash
|
||||
BOLD=`tput bold`
|
||||
BLUE=`tput setaf 4`
|
||||
NC=`tput sgr0`
|
||||
# check_firstrun()
|
||||
if [ ! -d ~/.wicd ]; then
|
||||
mkdir ~/.wicd
|
||||
fi
|
||||
# Make sure the user knows WHEREAREMYFILES ;-)
|
||||
if [ -e %DOCDIR%WHEREAREMYFILES ] && [ ! -L ~/.wicd/WHEREAREMYFILES ]; then
|
||||
ln -s %DOCDIR%WHEREAREMYFILES ~/.wicd/WHEREAREMYFILES
|
||||
fi
|
||||
if [ "$DISPLAY" = "" ] && [ -x "%BIN%wicd-curses" ]; then
|
||||
if [ ! -f ~/.wicd/CLIENT_CURSES_WARNING ]; then
|
||||
echo "NOTICE: We see that you don't have an X server active on this console."
|
||||
echo "We will now be starting ${BOLD}${BLUE}wicd-curses${NC}. If you desire"
|
||||
echo "more information about what is happening here, please read:"
|
||||
echo
|
||||
echo "man wicd-client"
|
||||
echo "-or-"
|
||||
echo "man wicd-curses"
|
||||
echo
|
||||
echo "We apologize for any inconvenience. This message will not be displayed again."
|
||||
echo "Please press enter to continue..."
|
||||
|
||||
read junk
|
||||
cat >>~/.wicd/CLIENT_CURSES_WARNING<<EOF
|
||||
This file is what wicd-client looks for so that it doesn't try to tell you that
|
||||
it is trying to launch the curses client so that it doesn't surprise non-
|
||||
technical users.
|
||||
|
||||
Please keep this file. If you remove it, then wicd-client will bark at
|
||||
you if you try to launch wicd-client on a screen that is not running X.
|
||||
|
||||
Or, you could just run "touch ~/.wicd/CLIENT_CURSES_WARNING", and the same
|
||||
objective will be met.
|
||||
|
||||
Have a nice day.
|
||||
|
||||
~The Wicd Developers
|
||||
EOF
|
||||
#touch ~/.wicd/CLIENT_CURSES_WARNING
|
||||
fi
|
||||
exec %BIN%wicd-curses
|
||||
fi
|
||||
|
||||
exec python -O %LIB%wicd-client.py $@
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
wicd-client \- manual page for wicd-client
|
||||
.SH DESCRIPTION
|
||||
wireless (and wired) connection daemon front\-end.
|
||||
|
||||
If wicd-curses(8) is instaled, and you attempt to run wicd-client without an active X server on the current terminal, wicd-client will attempt to run wicd-curses(8). It will warn you the first time this happens.
|
||||
.SS "Arguments:"
|
||||
.TP
|
||||
\fB\-n\fR \fB\-\-no\-tray\fR
|
||||
|
||||
5
setup.py
5
setup.py
@@ -1,3 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
#
|
||||
# Copyright (C) 2007 - 2008 Adam Blackburn
|
||||
# Copyright (C) 2007 - 2008 Dan O'Reilly
|
||||
@@ -410,13 +411,13 @@ try:
|
||||
data.append(( wpath.lib, ['curses/netentry_curses.py']))
|
||||
data.append(( wpath.bin, ['scripts/wicd-curses']))
|
||||
if not wpath.no_install_man:
|
||||
data.append(( wpath.mandir + 'man8', ['man/wicd-curses.8']))
|
||||
data.append(( wpath.mandir + 'man8/', ['man/wicd-curses.8']))
|
||||
piddir = os.path.dirname(wpath.pidfile)
|
||||
if not piddir.endswith('/'):
|
||||
piddir += '/'
|
||||
data.append (( piddir, [] ))
|
||||
if not wpath.no_install_docs:
|
||||
data.append(( wpath.docdir, [ 'INSTALL', 'LICENSE', 'AUTHORS', 'README', 'CHANGES' ]))
|
||||
data.append(( wpath.docdir, [ 'INSTALL', 'LICENSE', 'AUTHORS', 'README', 'CHANGES','other/WHEREAREMYFILES' ]))
|
||||
if not wpath.no_install_kde:
|
||||
data.append(( wpath.kdedir, [ 'other/wicd-tray.desktop' ]))
|
||||
if not wpath.no_install_init:
|
||||
|
||||
Reference in New Issue
Block a user