modemmanager: Add a reason to ConnectionStateChanged events.

This can be used by a connection manager to decide to respond in a different way
to certain kinds of disconnects (e.g. intentional versus unintentional versus
suspension).

TEST=None
This change introduces no additional code, so testing it in isolation is not
possible.

BUG=chromium-os:6744

Change-Id: Ie371e20ec7a003333eba013af3ad61c0e494a4ad
Signed-Off-By: Elly Jones <ellyjones@chromium.org>

Review URL: http://codereview.chromium.org/3413011
(cherry picked from commit 29a9674b818fd64c19bad84f526f6fa68edec174)
This commit is contained in:
Elly Jones
2010-09-15 13:22:25 -04:00
parent d4b2be5f6b
commit f047ca66a4

View File

@@ -93,6 +93,11 @@
Reason for state transition.
</tp:docstring>
</arg>
<arg name="reason" type="u" tp:type="MM_MODEM_CONNECTION_STATE_CHANGED_REASON">
<tp:docstring>
Reason for this state change.
</tp:docstring>
</arg>
</signal>
<property name="Device" type="s" access="read">
@@ -211,5 +216,24 @@
</tp:enumvalue>
</tp:enum>
<tp:enum name="MM_MODEM_CONNECTION_STATE_CHANGE_REASON" type="u">
<tp:enumvalue suffix="UNKNOWN" value="0">
<tp:docstring>
Reason unknown or not reportable.
</tp:docstring>
</tp:enumvalue>
<tp:enumvalue suffix="REQUESTED" value="1">
<tp:docstring>
Connection state change was requested by an interface user.
</tp:docstring>
</tp:enumvalue>
<tp:enumvalue suffix="SUSPEND" value="2">
<tp:docstring>
Connection state change was caused by a system suspend.
</tp:docstring>
</tp:enumvalue>
</tp:enum>
</interface>
</node>