Commit graph

44 commits

Author SHA1 Message Date
Dan Williams
3195956a0c 2004-10-08 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessAppletDbus.c
		- Die if NetworkManagerInfo dies, since it manages our lifetime


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@196 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-10-08 05:31:19 +00:00
John (J5) Palmieri
73488225cb 2004-10-07 John (J5) Palmieri <johnp@redhat.com>
* panel-applet/NMWirelessApplet.c
                - (nmwa_update_state): Hide notification icon if we are only
                        showing one wired card and no wireless interfaces
                        (Red Hat Bug #134895)


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@194 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-10-07 19:57:59 +00:00
Dan Williams
ce9f88bc19 2004-10-06 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerDevice.[ch]
	  src/NetworkManagerDbus.c
	  doc/NetworkManager DBUS API.txt
		- Add a new status tag "scanning", which is set when there
			is no active network connection, but NetworkManager is
			looking for an access point to associate with

	* panel-applet/main.c
		- Cast the applet appropriately for gtk_widget_show_all ()


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@192 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-10-07 01:50:39 +00:00
Jonathan Blandford
c96268564b Mon Oct 4 12:55:41 2004 Jonathan Blandford <jrb@redhat.com>
* panel-applet/eggtrayicon.[ch]:
        * panel-applet/main.c: Add missing file


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@190 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-10-04 16:56:39 +00:00
Jonathan Blandford
b46b359554 Fri Oct 1 18:26:03 2004 Jonathan Blandford <jrb@redhat.com>
* panel-applet/menu-info.c (nm_menu_wired_class_init): update look
        and feel.  We should be back to working, and have a good, clean
        look.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@183 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-10-01 22:26:45 +00:00
Jonathan Blandford
78bb8a008f Wed Sep 29 18:18:24 2004 Jonathan Blandford <jrb@redhat.com>
* configure.in: Add a temporary --enable-notification-icon.  This
        will prolly go away.

        * info-daemon/Makefile.am:
        * info-daemon/NetworkManagerInfo.c:
        * info-daemon/NetworkManagerInfo.h: Use a notification icon.

        * panel-applet/Makefile.am:
        * panel-applet/NMWirelessApplet.c: Turn into a notification icon
        * panel-applet/NMWirelessApplet.h:


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@180 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-29 22:22:05 +00:00
Jonathan Blandford
85d4ebd93c Tue Sep 28 16:35:20 2004 Jonathan Blandford <jrb@redhat.com>
* panel-applet/NMWirelessApplet.c: Fix deadlock.  Add a separator
        before 'select custom ESSID'.

        * panel-applet/menu-info.c: Start rewrite for better headers.  Not
        fully complete, but syncing in prep for merge.

        * panel-applet/icons/*png: New images


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@178 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-28 20:38:23 +00:00
Jonathan Blandford
4abfaae2b6 Wed Sep 22 14:19:48 2004 Jonathan Blandford <jrb@redhat.com>
* panel-applet/NMWirelessApplet.c: Only add essid's if we actually
        have a wireless card.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@171 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-22 18:23:01 +00:00
Jonathan Blandford
572cb80fe9 Wed Sep 22 14:05:48 2004 Jonathan Blandford <jrb@redhat.com>
* panel-applet/NMWirelessApplet.c: move the custom essid item.
        Also, get the right device strings.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@170 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-22 18:07:29 +00:00
Jonathan Blandford
7c6ac395c9 Wed Sep 22 13:51:45 2004 Jonathan Blandford <jrb@redhat.com>
* panel-applet/menu-info.c (nm_menu_network_draw_indicator): Flip
        the logic to make this right.

        * panel-applet/NMWirelessApplet.c (sort_networks_function): sort
        devices so that wired networks are always first.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@169 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-22 17:54:42 +00:00
Jonathan Blandford
bb33fbf767 Tue Sep 21 18:05:34 2004 Jonathan Blandford <jrb@redhat.com>
* configure.in: Add graphics

        * panel-applet/Makefile.am: Add graphics

        * panel-applet/icons/*: Add graphics

        * panel-applet/NMWirelessApplet.c: Use new menu times to display
        the icons fully lined up.

        * panel-applet/menu-info.c:
        * panel-applet/menu-info.h: Add another menu type.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@163 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-21 22:10:37 +00:00
Jonathan Blandford
63f4e9b4ec Fri Sep 17 14:04:34 2004 Jonathan Blandford <jrb@redhat.com>
* panel-applet/NMWirelessApplet.c: Redo the menu item code.

        * panel-applet/menu-item.[ch]: Wireless menu item.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@160 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-17 18:13:03 +00:00
Dan Williams
ee710f0377 2004-09-13 Dan Williams <dcbw@redhat.com>
* TODO: fix typo

	* docs/NetworkManager DBUS API.txt
		- Update for new signal strength changes

	* panel-applet/NMWirelessApplet.c
		- Make panel icon show strength of the current connection
		- Cleanups and memleak fixes

	* panel-applet/NMWirelessApplet.h
		- Add data members for signal strength on devices and networks

	* panel-applet/NMWirelessAppletDbus.c
		- Free more DBusErrors
		- Update for new signal strength changes
		- Make devices and networks more like real objects, use ref/unref methods
		- Actually unlock the mutex when updating the active device

	* src/NetworkManagerAP.c
		- Change AP functions and data members from "quality"->"strength"

	* src/NetworkManagerDbus.c
		- Kill "getMaxQuality" and "getQuality" methods
		- Add "getStrength" methods for Networks and Devices

	* src/NetworkManagerDevice.[ch]
		- Add accessors for device strength
		- Add functions to update strength for a device.  Note that not all drivers
			actually support signal strength for scanned access points (Atmel drivers
			being one)
		- Calculate signal strength for each AP during scan

	* src/NetworkManagerWireless.[ch]
		- Add function to return signal strength % from a device and a raw quality struct

	* test/nmclienttest.c
		- Update for new signal strength changes


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@156 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-13 17:43:16 +00:00
Dan Williams
ae080994c7 2004-09-11 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessApplet.c
	  panel-applet/NMWirelessAppletDbus.c
		- Start using NetworkDevice/WirelessNetwork structures in more places
		- Update for unified device/network forcing in NetworkManager

	* src/NetworkManager.c
		- some code consolidation

	* src/NetworkManagerDbus.c
		- (nm_dbus_nm_set_active_device): "setActiveDevice" now takes either one
			or two arguments:  the first is the NM ID of the device to switch to,
			and the second (optional) argument is the ESSID of a wireless network
			to use as well.
		- Get rid of "setNetwork" method due to above change

	* src/NetworkManagerDevice.c
		- (nm_device_new): perform scan and update best AP on device creation
		- nm_device_activation_cancel_if_needed()->nm_device_activation_should_cancel()
		- nm_device_activation_signal_cancel()->nm_device_activation_cancel(), and
			spin waiting for cancellation to finish before returning

	* src/NetworkManagerPolicy.c
		- Changes here clarify the situations in which a device switch occurs, and
			make sure to keep using a forced device and network if the user gives
			us one
		- Remove old unused code


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@149 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-12 03:06:44 +00:00
Dan Williams
9e32ee7856 2004-09-09 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessAppletDbus.c
		- Pull fresh devices and networks from NM when wireless networks
			change.  Provides faster feedback of a forced wireless network

	* src/NetworkManagerDbus.c
		- Return error when "getMaxQuality" is called on a wired device
		- Make best_ap freezing actually work again, and signal cancellation
			of activation if there's already a device activation when the user
			freezes the best_ap

	* src/NetworkManagerDevice.c
		- Don't clear out the best_ap for wireless devices when the link goes
			down, that's done elsewhere
		- Kill any dhcp daemons when cancelling device activation since they
			may be stuck waiting for a DHCP address, and since we're cancelling
			activation we don't care about that anymore

	* src/NetworkManagerPolicy.c
		- Make sure to unref the device we ref earlier (we refed it to make sure
			it stuck around during device activation and such)
		- If we were going to change the best device, but its activating currently
			(and therefore the change didn't occur due to the check earlier)
			we mark the state changed to we come back to it later when device
			activation has canceled and its no longer activating

	* src/backends/NetworkManagerRedHat.c
		- SIGKILL dhcp daemons rather than SIGTERM-ing them


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@143 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-09 21:34:40 +00:00
Dan Williams
2b782920d6 2004-09-09 Dan Williams <dcbw@redhat.com>
NOTE: this commit changes the behavior of wireless devices in
	NetworkManager.  They are now up all the time, scanning all
	the time.  Only the active device has an IP address and routing
	information set up however.  Also, NetworkManager will no longer
	opportunistically switch wireless networks when a better one
	comes in range, it will remain associated with one wireless network
	until that one drops out.

	* panel-applet/NMWirelessApplet.c
	  panel-applet/NMWirelessAppletDbus.c
		- List all wireless cards and their respective networks

	* src/NMLoadModules
		- Use full path to /sbin/ip

	* src/NetworkManager.c
		- Keep wireless devices up all the time so they can scan

	* src/NetworkManagerDbus.c
		- On a WirelessNetworkUpdate signal from NMI, don't update
			the "best" AP

	* src/NetworkManagerDevice.c
		- (nm_device_set_link_active): clear out the best ap for
			wireless devices when the link is set to FALSE
		- Scan on all wireless cards, all the time
		- (nm_device_activation_worker): split out the wireless card
			link-waiting code to a separate function
		- Keep wireless cards up even if device activation fails
		- Don't update the "best" ap as much

	* src/NetworkManagerPolicy.c
		- Don't update the best ap when checking if its frozen,
			let link checking clear out a frozen best ap for us

	* src/NetworkManagerWireless.c
		- Scan on all wireless cards, all the time


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@140 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-09 20:02:59 +00:00
Dan Williams
b0d1e68dd4 2004-09-08 Dan Williams <dcbw@redhat.com>
* panel-applet/no-networkmanager.png
	  panel-applet/Makefile.am
	  panel-applet/NMWirelessApplet.c
		- Add a "NetworkManager not running" icon and use it
		- Use new consolidated GConf keys rather than Preferred/Trusted

	* TODO: update

	* info-daemon/NetworkManagerInfo.c
	  info-daemon/NetworkManagerInfoDbus.[ch]
	  info-daemon/NetworkManagerInfoPassphraseDialog.c
		- There are now no longer two separate lists of wireless networks,
			but one list where each network is "trusted" or not trusted
		- Add a "getNetworkTrusted" dbus method
		- "WirelessNetworkUpdate" signal now sent rather than
			"PreferredNetworkUpdate/TrustedNetworkUpdate" signals
		- Start freeing some dbus errors (not completed yet)

	* info-daemon/passphrase.glade
		- Remove the "don't show" hints for pager and taskbar
		- Add a title since its going to be in the taskbar

	* src/NetworkManager.[ch]
	  src/NetworkManagerAPList.[ch]
		- There are now no longer two separate lists of wireless networks,
			but one list where each network is "trusted" or not trusted

	* src/NetworkManagerAP.[ch]
		- Add get/set "trusted" accessors and data bit

	* src/NetworkManagerDbus.[ch]
		- Add function to get "trusted" status of a network from NetworkManagerInfo
		- Trap new WirelessNetworkUpdate signal rather than old separate signals

	* src/NetworkManagerDevice.[ch]
		- Add per-device config data (ip4 addr, gateway, netmask) and accessors
		- (nm_device_new): Get device config from backend when initializing devices
		- (nm_device_activation_worker): Split out device configuration on
			activation to deal with static/dynamic IP differences, and try encryption
			fallbacks on a device if the encryption method for the best AP is not good
		- (nm_device_update_best_ap): convert to new consolidated access point lists from
			NetworkManagerInfo, and copy over latest NMI info to best_ap when setting it

	* src/NetworkManagerWireless.c
		- libgcrypt code wasn't converting the MD5 digest to an ascii string, fix it

	* src/backends/NetworkManagerRedHat.c
	  src/backends/NetworkManagerSystem.h
		- (nm_system_device_update_config_info): Add function to get device configuration
			from system data in ifcfg-* files

	* src/backends/NetworkManagerDebian.c
	  src/backends/NetworkManagerGentoo.c
	  src/backends/NetworkManagerSlackware.c
		- Add stub functions for getting device configuration


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@131 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-09-08 18:14:42 +00:00
Colin Walters
6871fe28bc 2004-08-29 Colin Walters <walters@verbum.org>
* test/nminfotest.c: Include string.h and stdlib.h.
	(get_network_string_property, get_networks_of_type): Return NULL.

	* test/nmclienttest.c (get_device_name, get_active_device): Return
	NULL.

	* src/backends/NetworkManagerRedHat.c (nm_system_device_stop_dhcp): Just
	use strlen, fgets always NULL-terminates the string.

	* src/NetworkManagerDbus.c (nm_dbus_nmi_filter,
	dbus_message_get_member): Remove /* in comment.

	* src/NetworkManagerUtils.c (LOCKING_DEBUG): Ditto.

	* src/NetworkManager.c (quit): Unused, delete.
	(nm_data_free): Cast arg to GFunc.

	* panel-applet/NMWirelessAppletDbus.c: Need to include
	string.h, and dbus-glib-lowlevel.h (the latter is needed
	for dbus_connection_setup_with_g_main at present).
	(nmwa_dbus_update_wireless_network_list): Parenthesize
	assignment in conditional.
	(nmwa_dbus_worker): Return NULL.

	* panel-applet/NMWirelessApplet.c (nmwa_redraw)
	(nmwa_get_menu_pos, nmwa_toplevel_menu_activate)
	(nmwa_menu_add_text_item, nmwa_setup_widgets): Kill unused variables.
	(nmwa_populate_menu): Return NULL on failure, instead of just
	return;

	* initscript/NMLaunchHelper.c (g_timeout_add): Cast arg to GSourceFunc.

	* info-daemon/NetworkManagerInfoNetworksDialog.c (nmi_networks_dialog_init): Kill unused
	variables.

	* info-daemon/NetworkManagerInfo.c (nmi_print_usage): Unused,
	delete.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@105 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-29 06:06:51 +00:00
Colin Walters
5ddc7519a5 2004-08-29 Colin Walters <walters@verbum.org>
* panel-applet/NMWirelessApplet.c: Include config.h.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@102 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-29 05:36:34 +00:00
Dan Williams
7fd3e529b4 Fri Aug 28 2004 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessApplet.c
		- Make current device bold
		- Show more user-friendly device name if we got one from hal

	* panel-applet/NMWirelessAppletDbus.c
		- Grab "info.product" key from hal for network devices
		- Cache the current active device


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@92 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-27 19:42:47 +00:00
Dan Williams
d52e623fde Thu Aug 26 2004 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessApplet.c
		- Remove debugging code
		- Enable device switching from menus

	* panel-applet/NMWirelessAppletDbus.[ch]
		- Method for asking NM to switch devices

	* src/NetworkManagerDevice.c
		- Set dev->activating earlier, avoids race between
			the dbus signal of "DeviceActivating" and setting
			dev->activating (which is what NM's "status" method call
			looks at)


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@83 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-26 21:11:27 +00:00
Dan Williams
97e86a1857 Add
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@82 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-26 20:07:26 +00:00
Dan Williams
305ff0adb0 Thu Aug 26 2004 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessApplet.[ch]
		- Rework menu code to add devices to menu, and to show
			signal strength for each access point.  Code cleanups
			too.

	* panel-applet/NMWirelessAppletDbus.c
		- Grab network devices from NetworkManager too
		- Grab quality information from NM for wireless networks

	* src/NetworkManagerDbus.[ch]
		- Add dbus methods for getting the HAL UDI from a device and
			for getting its base quality, if its wireless
		- Consolidate some functions (wireless network notifications,
			device notifications)
		- Add method for requesting NM to use a particular device

	* src/NetworkManager.c
		- Change for function consolidations from NetworkManagerDbus.c
		- Implement active device locking and user-requested devices
			(ie, tell NM to use a particular device instead of the one
			it autochose)

	* src/NetworkManagerDevice.c
		- Add method for getting the base quality of a device, if its
			wireless
		- Grab device base quailty info from iwlib during scans

	* src/NetworkManagerPolicy.c
		- Use a user-requested device rather than the auto-chosen device
			if we are told to


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@81 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-26 20:05:24 +00:00
Jonathan Blandford
d3aff52822 Thu Aug 26 15:12:36 2004 Jonathan Blandford <jrb@redhat.com>
* Makefile.am: add po as a supdir

        * autogen.sh: use gnome-autogen.sh

        * initscript/Gentoo/.cvsignore:
        * initscript/RedHat/.cvsignore: Shut up cvs

        * panel-applet/Makefile.am: Define GNOMELOCALEDIR for bonobo.

        * panel-applet/NMWirelessApplet.c: (nmwa_populate_menu),
        (nmwa_fill): Use gettext.

        * configure.in: add gettext support
        * po/.cvsignore:
        * po/NetworkManager.pot:
        * po/POTFILES.in:


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@80 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-26 19:14:26 +00:00
Seth Nickell
b20bd14ea3 * panel-applet/NMWirelessApplet.c: (nmwa_destroy),
(nmwa_menu_item_activate), (nmwa_toplevel_menu_activate),
	(nmwa_add_menu_item), (nmwa_menu_item_data_free),
	(nmwa_dispose_menu_items), (nmwa_populate_menu),
	(nmwa_setup_widgets), (do_not_eat_button_press), (nmwa_new):
	* panel-applet/NMWirelessApplet.h:

	Use a menu bar instead of a button for the main clickable
	thingy.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@79 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-26 04:20:33 +00:00
Dan Williams
21862371b6 2004-08-25 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessApplet.c
		- Rebuild the menu whenever a user clicks


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@75 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-26 02:25:49 +00:00
Dan Williams
d9abb16b8b Take out the "active" text
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@74 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-26 01:57:10 +00:00
Dan Williams
efb70bd972 2004-08-25 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessApplet.c
		- (nmwa_udpate_state): Set panel icon to "wired" (for lack of better ones)
			when NM isn't around or when its not connected

	* src/NetworkManagerDevice.c
		- (nm_device_activation_worker): Make sure to reset dev->activating if we get
			canceled.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@73 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-26 01:37:03 +00:00
Dan Williams
bbc8ab5e1a 2004-08-25 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessAppletDbus.c
		- (nmwa_dbus_get_bool, nmwa_dbus_get_network_encrypted): correct method name
			for getting encryption, and don't stop on "val" once we've gotten it
			from NetworkManager.  Short form:  encryption should now show up.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@72 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-26 01:25:08 +00:00
Dan Williams
7df00044ca 2004-08-25 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessApplet.c
		- Set ESSID on a gconf trusted network too when force-setting the wireless
			network to associate with


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@71 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-26 01:16:19 +00:00
Dan Williams
e09969112f 2004-08-25 Dan Williams <dcbw@redhat.com>
* panel-applet/*
		- Rework the panel applet to do all DBUS communication in a separate
			thread


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@70 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-26 00:33:08 +00:00
Dan Williams
07258fd5e1 2004-08-23 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessApplet.c
		- Update our state every second to get more responsive panel icon
		- (nmwa_update_state): remove bogus applet->pix_state = PIX_WIRED that
			was causing our marching ants status blips to never move when
			looking for a wireless network

	* src/NetworkManagerDevice.c
		- (nm_device_activation_begin): return if activation has already begun
		- (nm_device_do_normal_scan): merge WEP key and priority from the
			trusted/preferred network into the device's access point when the
			scan list is processed


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@60 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-23 19:09:19 +00:00
Dan Williams
b770456511 2004-08-20 Dan Williams <dcbw@redhat.com>
* info-daemon/NetworkManagerInfoPassphraseDialog.c
		- (nmi_passphrase_dialog_ok_clicked): when updating the wep key
			for a network, set the essid as well since it may not exist yet
		- (nmi_passphrase_dialog_init): don't star out the passphrase field,
			since WEP keys/passphrases are long and prone to entry-error

	* panel-applet/Makefile.am
	  panel-applet/wired.png
		- Add (pulled from system-config-network temporarily)

	* panel-applet/NMWirelessApplet.[ch]
		- Show wired picture when a wired connection is used
		- Rename wireless icon enums, adding WIRELESS

	* src/NetworkManagerDevice.c
		- (nm_device_activate_wireless): unset encryption before bringing
			down the card and setting the essid
		- (nm_device_activatin_worker): request a key from the user if the
			AP we are connecting to is encrypted but we don't have a key
			for it yet
		- (nm_device_set_user_key_for_network): fix missing '== 0' for a
			strcmp() that prevented a user-entered key from actually getting
			used


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@58 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-20 18:18:37 +00:00
Dan Williams
461f757662 update
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@57 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-16 19:49:34 +00:00
Dan Williams
b6b069d02e 2004-08-13 Dan Williams <dcbw@redhat.com>
* panel-applet/Makefile.am
		- Fix up cleanfiles and server_DATA/server_in_files


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@52 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-13 17:03:51 +00:00
Dan Williams
6b0bddf916 2004-08-13 Dan Williams <dcbw@redhat.com>
* configure.in
	  panel-applet/Makefile.am
		- Fixes to allow distcheck to pass


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@51 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-13 15:59:47 +00:00
Dan Williams
0895829142 2004-08-12 Dan Williams <dcbw@redhat.com>
* info-daemon/passphrase.glade
		- Set window title to " "

	* panel-applet/Makefile.am
	  panel-applet/keyring.png
		- Deliver to correct place

	* panel-applet/NMWirelessApplet.[ch]
		- Add comments
		- Remove applet->have_active_device as its no longer used
		- (nmwa_load_theme): load keyring.png too
		- (error_dialog): remove
		- (show_warning_dialog): subsume functionality of error dialog too
		- (nmwa_destroy, nmwa_new): create and dispose of an application-wide GConfClient
		- (nmwa_handle_network_choice): add to deal with user clicking on an item from
			the networks menu
		- (nmwa_menu_item_activated): GtkMenuItem "activate" signal handler
		- (nmwa_button_clicked, nmwa_setup_widgets): create and populate the menu on startup
			and when we get broadcasts of changed wireless access points only, not when the
			user clicks on the button to display the menu (too long of a wait)
		- (nmwa_add_menu_item): Make active network bold, and place a keyring icon beside
			networks that are encrypted
		- (nmwa_dispose_menu, nmwa_menu_item_data_free): dispose of the data we place on each
			menu item with g_object_set_data()

	* panel-applet/NMWirelessAppletDbus.[ch]
		- (nmwa_dbus_get_bool): add method to return boolean value from dbus message
		- (nmwa_dbus_get_active_network): add (nmwa_dbus_get_string() wrapper to get active network)
		- (nmwa_dbus_add_networks_to_menu): clean up, only show one instance of each ESSID in the menu
		- (nmwa_dbus_set_network): force NetworkManager to use a particular network for wireless cards
		- (nmwa_dbus_init, nmwa_dbus_filter): Trap network appear/disappear and device
			activation/deactivation signals and rebuild the menu when they happen

	* src/NetworkManager.c
		- (main): use new nm_spawn_process() rather than system()

	* src/NetworkManagerDbus.c
		- (nm_dbus_devices_handle_request): don't compare AP structure addresses directly, but essids
			instead.  Since we can now force best_aps to stick around, the AP structure to which
			dev->options.wireless.best_ap points to won't necessarily be in the device's device list
			if a scan has happened since the best_ap was frozen.  Also add "setNetwork" method
			to freeze the best_ap.

	* src/NetworkManagerDevice.[ch]
		- (nm_device_activation_worker): Use new nm_spawn_process() call rather than system()
		- (nm_device_*_best_ap): add freeze/unfreeze/get_frozen functions, and don't really update
			the best_ap in nm_device_update_best_ap() if the best_ap is frozen AND in the device's
			ap list

	* src/NetworkManagerUtils.[ch]
		- (nm_spawn_process): add replacement for system() usage


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@48 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-12 19:58:01 +00:00
Dan Williams
f9b8cb84d1 2004-08-11 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessApplet.[ch]
		- Fix up copyright and credits to include Bastien and Eskil,
			who created the gnome-applets wireless applet, from whose
			skeleton this one was created
		- Rework nmwa_update_state()/nmwa_draw() so that state and which
			pixmap to draw is computed during nmwa_update_state()
		- Applet now shows itself all the time due to panel packing issues
			which caused the applet to previously never come back after hiding.
			When a wired device is the active device, the applet shows "not connected"

	* panel-applet/NMWirelessAppletDbus.[ch]
		- Clean up error messages and show what function they are from
		- nmwa_dbus_get_active_wireless_device()->nmwa_dbus_get_active_device()
		- Add new device type getters, and a status getter

	* src/NetworkManagerDbus.c
		- (nm_dbus_devices_handle_request): Don't return an active network unless that
			network is actually in the device's ap list
		- (nm_dbus_nm_message_handler): Fix silly mistake returning status

	* src/NetworkManagerDevice.c
		- (nm_device_update_best_ap): If the best AP is NULL, clear out the ESSID of the
			card

	* test/nmclienttest.c
		- Report status of NetworkManager too


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@47 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-11 19:31:41 +00:00
Dan Williams
d06aa3e6ff 2004-08-11 Dan Williams <dcbw@redhat.com>
* info-daemon/NetworkManagerInfo.c:
		- (main): clean up Seth's code style

	* info-daemon/NetworkManagerInfoDbus.c:
		- Use the more aptly-named path/service/interface constants from NetworkManager
		- Don't return empty strings ("") as object paths ever, instead return errors

	* panel-applet/NMWirelessApplet.c:
		- Clean up Seth's code style

	* src/NetworkManager.[ch]
		- (nm_remove_device_from_list): remove anything having to do with pending_device
		- (main, nm_print_usage): change --daemon=[yes|no] -> --no-daemon

	* src/NetworkManagerAPList.[ch]
		- Move Iter struct right above the iter functions to preserve opacity
		- (nm_ap_list_remove_ap): implement
		- (nm_ap_list_update_network): deal with errors returned from nm_dbus_get_network_priority(),
			remove AP if NetworkManagerInfo doesn't know anything about it
		- (nm_ap_list_diff): user NMAPList iterators
		- (nm_ap_list_print_members): implement debugging function

	* src/NetworkManagerDbus.[ch]
		- (nm_dbus_nm_get_active_device): remove anything to do with pending_device
		- (nm_dbus_get_user_key_for_network): remove DBusPendingCall stuff (unused),
			and move the actual key setting stuff into NetworkManagerDevice.c
		- (nm_dbus_get_network_priority): return -1 now on errors
		- (nm_dbus_nmi_filter): fix strcmp() error that caused PreferredNetworkUpdate signals to
			get lost, and force the active device to update its "best" ap when AP lists change
		- (nm_dbus_nm_message_handler): Update conditions for returning "connecting" for a "status"
			method call due to pending_device member removal

	* src/NetworkManagerDevice.[ch]
		- Move NMDevice structure to the top
		- Add a wireless scan mutex and a best_ap mutex to the Wireless Options structure
		- Remove Pending Action stuff from everywhere
		- (nm_device_activation_*): We now "begin" activation and start a thread to do the
			activation for us.  This thread blocks until all conditions for activation have
			been met (ie for wireless devices, we need a valid WEP key and a "best" ap), and
			then setup up the interface and runs dhclient.  We have to do this because there
			is no guaruntee how long dhclient takes, and while we are blocking on it, we cannot
			run our main loop and respond to dbus method calls or HAL device removals/inserts
		- (nm_device_set_user_key_for_network): Move logic here from NetworkManagerDbus.c so we
			can tell nm_device_activation_worker() that we've got a key
		- (nm_device_*_best_ap): lock access to best_ap member of Wireless Options structure
		- (nm_device_get_path_for_ap): dumb it down so the list doesn't lock against itself when
			diffing (AP appear/disappear signal functions make sure the AP is actually in the device's
list)
		- (nm_device_update_best_ap): move logic from nm_wireless_is_ap_better() here

	* src/NetworkManagerPolicy.c
		- Remove anything to do with pending_device
		- Adjust device activation to deal with activation-in-worker-thread

	* src/NetworkManagerUtils.c
		- Clean up locking debugging a bit

	* src/NetworkManagerWireless.[ch]
		- (nm_wireless_is_ap_better): remove, stick logic in nm_device_update_best_ap().  This function
			was badly named and is better as a device function

	* panel-applet/.cvsignore: add


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@46 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-11 18:14:02 +00:00
Seth Nickell
8e04fc11ff * panel-applet/NMWirelessApplet.c: (nmwa_timeout_handler),
(nmwa_button_clicked), (nmwa_populate_menu), (nmwa_setup_widgets),
	(nmwa_new):
	* src/NetworkManagerDbus.c: (nm_dbus_nmi_filter):

	Don't load the menus until clicked on (also removes a call outside
	normal code paths at first load).

	Hide applet when NM is not present.

	Improve printf debugging stuff.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@45 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-09 19:47:21 +00:00
Seth Nickell
eacb8da619 2004-08-06 Seth Nickell <seth@gnome.org>
* panel-applet/NMWirelessApplet.c: (nmwa_new):

	Check the error code when getting a connection.

	* panel-applet/NMWirelessAppletDbus.c: (nmwa_dbus_init):

	Check if the NM service exists when initializing (rather than
	assuming it does not).

	* src/NetworkManagerDbus.c: (nm_dbus_init):

	Don't acquire the well-known service name until we have
	registered object/path handlers and can actually receive
	calls.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@42 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-06 20:24:53 +00:00
Dan Williams
00a4a641d6 Don't pass blank path through dbus
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@41 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-06 19:43:37 +00:00
Dan Williams
0505220a13 convert warning dialogs->fprintfs
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@40 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-06 18:57:51 +00:00
Dan Williams
e8b7b7c07d 2004-08-06 Dan Williams <dcbw@redhat.com>
* panel-applet/*
		- Add panel applet

	* src/NetworkManagerPolicy.c
	  src/NetworkManager.c
		- Get access point lists from NetworkManagerInfo on-demand,
			and look for ServiceCreate/ServiceDeleted signals to see when
			we should query NMI for lists
	* src/NetworkManagerAPList.c
		- Make sure to init the list's mutex
		- Convert traversals of the list over to the list iter functions

	* src/NetworkManagerDbus.[ch]
		- Use more aptly-named path/service/interface constants
		- Treat both active and pending devices the same for "getActiveDevice"
		- Add a "status" method returning "connected", "connecting", or "disconnected"

	* src/NetworkManagerDevice.c
		- Honor "ignored" network list when picking best ap to use


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@39 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2004-08-06 18:19:06 +00:00