summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-x.gitignore1
-rw-r--r--ZeroTierUI/networkwidget.ui367
-rwxr-xr-xext/installfiles/mac/uninstall.sh23
3 files changed, 212 insertions, 179 deletions
diff --git a/.gitignore b/.gitignore
index 6a09d086..aecb2fb2 100755
--- a/.gitignore
+++ b/.gitignore
@@ -35,3 +35,4 @@ mac-tap/tuntap/tap.kext
/zt1-*-install
/file2lz4c
.qmake.stash
+*.autosave
diff --git a/ZeroTierUI/networkwidget.ui b/ZeroTierUI/networkwidget.ui
index 8b2c51fb..84c26829 100644
--- a/ZeroTierUI/networkwidget.ui
+++ b/ZeroTierUI/networkwidget.ui
@@ -40,28 +40,7 @@
</property>
<item>
<widget class="QWidget" name="leftWidget" native="true">
- <property name="sizePolicy">
- <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
- <horstretch>0</horstretch>
- <verstretch>0</verstretch>
- </sizepolicy>
- </property>
- <layout class="QFormLayout" name="formLayout">
- <property name="fieldGrowthPolicy">
- <enum>QFormLayout::ExpandingFieldsGrow</enum>
- </property>
- <property name="labelAlignment">
- <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
- </property>
- <property name="formAlignment">
- <set>Qt::AlignHCenter|Qt::AlignTop</set>
- </property>
- <property name="horizontalSpacing">
- <number>6</number>
- </property>
- <property name="verticalSpacing">
- <number>2</number>
- </property>
+ <layout class="QVBoxLayout" name="verticalLayout_2">
<property name="leftMargin">
<number>0</number>
</property>
@@ -74,152 +53,61 @@
<property name="bottomMargin">
<number>0</number>
</property>
- <item row="2" column="0">
- <widget class="QLabel" name="label_2">
- <property name="text">
- <string>Network ID:</string>
- </property>
- <property name="textFormat">
- <enum>Qt::PlainText</enum>
- </property>
- </widget>
- </item>
- <item row="2" column="1">
- <widget class="QPushButton" name="networkIdPushButton">
- <property name="font">
- <font>
- <weight>75</weight>
- <bold>true</bold>
- </font>
- </property>
- <property name="toolTip">
- <string>Click to copy network ID to clipboard.</string>
- </property>
- <property name="styleSheet">
- <string notr="true">QPushButton {
- border: 0;
- padding: 0;
- margin: 0;
- text-align: left;
- background-color: transparent;
-}
-
-QPushButton:focus {
- background-color: rgba(0,0,0,25);
-}
-
-QPushButton:hover {
- background-color: rgba(0,0,0,25);
-}
-</string>
- </property>
- <property name="text">
- <string>0000000000000000</string>
- </property>
- <property name="flat">
- <bool>true</bool>
- </property>
- </widget>
- </item>
- <item row="3" column="0">
- <widget class="QLabel" name="label_3">
- <property name="text">
- <string>Name:</string>
- </property>
- <property name="textFormat">
- <enum>Qt::PlainText</enum>
- </property>
- </widget>
- </item>
- <item row="3" column="1">
+ <item>
<widget class="QLabel" name="nameLabel">
- <property name="font">
- <font>
- <weight>75</weight>
- <bold>true</bold>
- </font>
- </property>
- <property name="text">
- <string>?</string>
- </property>
- <property name="textFormat">
- <enum>Qt::PlainText</enum>
- </property>
- </widget>
- </item>
- <item row="4" column="0">
- <widget class="QLabel" name="label_5">
- <property name="text">
- <string>Type:</string>
- </property>
- <property name="textFormat">
- <enum>Qt::PlainText</enum>
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Expanding" vsizetype="Preferred">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
</property>
- </widget>
- </item>
- <item row="4" column="1">
- <widget class="QLabel" name="networkTypeLabel">
<property name="font">
<font>
- <weight>75</weight>
- <bold>true</bold>
+ <pointsize>15</pointsize>
</font>
</property>
- <property name="text">
- <string>?</string>
- </property>
- <property name="textFormat">
- <enum>Qt::PlainText</enum>
- </property>
- </widget>
- </item>
- <item row="5" column="0">
- <widget class="QLabel" name="label">
- <property name="text">
- <string>Status:</string>
- </property>
- <property name="textFormat">
- <enum>Qt::PlainText</enum>
+ <property name="styleSheet">
+ <string notr="true">background-color: rgba(0,0,0,25);
+padding: 0.25em;
+margin: 0;</string>
</property>
- </widget>
- </item>
- <item row="6" column="0">
- <widget class="QLabel" name="label_4">
<property name="text">
- <string>Device:</string>
+ <string>networkname</string>
</property>
<property name="textFormat">
<enum>Qt::PlainText</enum>
</property>
- </widget>
- </item>
- <item row="6" column="1">
- <widget class="QLabel" name="deviceLabel">
- <property name="font">
- <font>
- <weight>75</weight>
- <bold>true</bold>
- </font>
- </property>
- <property name="text">
- <string>?</string>
+ <property name="alignment">
+ <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
</property>
- <property name="textFormat">
- <enum>Qt::PlainText</enum>
+ <property name="textInteractionFlags">
+ <set>Qt::NoTextInteraction</set>
</property>
</widget>
</item>
- <item row="5" column="1">
- <widget class="QWidget" name="widget" native="true">
+ <item>
+ <widget class="QWidget" name="networkStatsWidget" native="true">
<property name="sizePolicy">
- <sizepolicy hsizetype="Expanding" vsizetype="Preferred">
+ <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <layout class="QHBoxLayout" name="horizontalLayout_3">
- <property name="spacing">
- <number>12</number>
+ <layout class="QFormLayout" name="formLayout">
+ <property name="fieldGrowthPolicy">
+ <enum>QFormLayout::ExpandingFieldsGrow</enum>
+ </property>
+ <property name="labelAlignment">
+ <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+ </property>
+ <property name="formAlignment">
+ <set>Qt::AlignHCenter|Qt::AlignTop</set>
+ </property>
+ <property name="horizontalSpacing">
+ <number>6</number>
+ </property>
+ <property name="verticalSpacing">
+ <number>2</number>
</property>
<property name="leftMargin">
<number>0</number>
@@ -233,14 +121,65 @@ QPushButton:hover {
<property name="bottomMargin">
<number>0</number>
</property>
- <item>
- <widget class="QLabel" name="statusLabel">
- <property name="sizePolicy">
- <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
- <horstretch>0</horstretch>
- <verstretch>0</verstretch>
- </sizepolicy>
+ <item row="2" column="0">
+ <widget class="QLabel" name="label_2">
+ <property name="text">
+ <string>Network ID:</string>
+ </property>
+ <property name="textFormat">
+ <enum>Qt::PlainText</enum>
+ </property>
+ </widget>
+ </item>
+ <item row="2" column="1">
+ <widget class="QPushButton" name="networkIdPushButton">
+ <property name="font">
+ <font>
+ <weight>75</weight>
+ <bold>true</bold>
+ </font>
+ </property>
+ <property name="toolTip">
+ <string>Click to copy network ID to clipboard.</string>
+ </property>
+ <property name="styleSheet">
+ <string notr="true">QPushButton {
+ border: 0;
+ padding: 0;
+ margin: 0;
+ text-align: left;
+ background-color: transparent;
+}
+
+QPushButton:focus {
+ background-color: rgba(0,0,0,25);
+}
+
+QPushButton:hover {
+ background-color: rgba(0,0,0,25);
+}
+</string>
+ </property>
+ <property name="text">
+ <string>0000000000000000</string>
+ </property>
+ <property name="flat">
+ <bool>true</bool>
</property>
+ </widget>
+ </item>
+ <item row="3" column="0">
+ <widget class="QLabel" name="label_5">
+ <property name="text">
+ <string>Type:</string>
+ </property>
+ <property name="textFormat">
+ <enum>Qt::PlainText</enum>
+ </property>
+ </widget>
+ </item>
+ <item row="3" column="1">
+ <widget class="QLabel" name="networkTypeLabel">
<property name="font">
<font>
<weight>75</weight>
@@ -255,40 +194,125 @@ QPushButton:hover {
</property>
</widget>
</item>
- <item>
- <widget class="QLabel" name="ageLabel">
+ <item row="4" column="0">
+ <widget class="QLabel" name="label">
+ <property name="text">
+ <string>Status:</string>
+ </property>
+ <property name="textFormat">
+ <enum>Qt::PlainText</enum>
+ </property>
+ </widget>
+ </item>
+ <item row="4" column="1">
+ <widget class="QWidget" name="widget" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
+ <layout class="QHBoxLayout" name="horizontalLayout_3">
+ <property name="spacing">
+ <number>12</number>
+ </property>
+ <property name="leftMargin">
+ <number>0</number>
+ </property>
+ <property name="topMargin">
+ <number>0</number>
+ </property>
+ <property name="rightMargin">
+ <number>0</number>
+ </property>
+ <property name="bottomMargin">
+ <number>0</number>
+ </property>
+ <item>
+ <widget class="QLabel" name="statusLabel">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="font">
+ <font>
+ <weight>75</weight>
+ <bold>true</bold>
+ </font>
+ </property>
+ <property name="text">
+ <string>?</string>
+ </property>
+ <property name="textFormat">
+ <enum>Qt::PlainText</enum>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QLabel" name="ageLabel">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Expanding" vsizetype="Preferred">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="font">
+ <font>
+ <pointsize>8</pointsize>
+ </font>
+ </property>
+ <property name="text">
+ <string>(configuration is 0 seconds old)</string>
+ </property>
+ <property name="textFormat">
+ <enum>Qt::PlainText</enum>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <spacer name="horizontalSpacer_2">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>1</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ </layout>
+ </widget>
+ </item>
+ <item row="5" column="0">
+ <widget class="QLabel" name="label_4">
+ <property name="text">
+ <string>Device:</string>
+ </property>
+ <property name="textFormat">
+ <enum>Qt::PlainText</enum>
+ </property>
+ </widget>
+ </item>
+ <item row="5" column="1">
+ <widget class="QLabel" name="deviceLabel">
<property name="font">
<font>
- <pointsize>8</pointsize>
+ <weight>75</weight>
+ <bold>true</bold>
</font>
</property>
<property name="text">
- <string>(configuration is 0 seconds old)</string>
+ <string>?</string>
</property>
<property name="textFormat">
<enum>Qt::PlainText</enum>
</property>
</widget>
</item>
- <item>
- <spacer name="horizontalSpacer_2">
- <property name="orientation">
- <enum>Qt::Horizontal</enum>
- </property>
- <property name="sizeHint" stdset="0">
- <size>
- <width>40</width>
- <height>1</height>
- </size>
- </property>
- </spacer>
- </item>
</layout>
</widget>
</item>
@@ -455,7 +479,6 @@ QListWidget:hover {
</layout>
</widget>
<tabstops>
- <tabstop>networkIdPushButton</tabstop>
<tabstop>ipListWidget</tabstop>
<tabstop>leaveNetworkButton</tabstop>
</tabstops>
diff --git a/ext/installfiles/mac/uninstall.sh b/ext/installfiles/mac/uninstall.sh
index b9563a11..626db73f 100755
--- a/ext/installfiles/mac/uninstall.sh
+++ b/ext/installfiles/mac/uninstall.sh
@@ -10,11 +10,20 @@ if [ "$UID" -ne 0 ]; then
exit 1
fi
-echo
+# Run with -q to be quieter and run without delay
+quickAndQuiet=0
+if [ "$1" = "-q" ]; then
+ quickAndQuiet=1
+ echo() { :; }
+fi
-echo "This will uninstall ZeroTier One, hit CTRL+C to abort."
-echo "Waiting 5 seconds..."
-sleep 5
+echo
+
+if [ $quickAndQuiet -eq 0 ]; then
+ echo "This will uninstall ZeroTier One, hit CTRL+C to abort."
+ echo "Waiting 5 seconds..."
+ sleep 5
+fi
echo "Unloading and removing LaunchDaemons item..."
launchctl unload /Library/LaunchDaemons/com.zerotier.one.plist
@@ -27,11 +36,11 @@ killall -KILL zerotier-one >>/dev/null 2>&1
sleep 1
echo "Unloading kernel extension..."
-kextunload "$ztpath/tap.kext"
+kextunload "$ztpath/tap.kext" >>/dev/null 2>&1
echo "Erasing UI app, binary, and support files..."
-cd $ztpath
-rm -rfv "$ztapp" zerotier-one *.persist authtoken.secret identity.public *.log *.pid *.kext *.sh
+cd "$ztpath"
+rm -rfv "$ztapp" zerotier-one *.persist authtoken.secret identity.public *.log *.pid *.kext *.sh networks.d updates.d shutdownIfUnreadable
echo "Done."
echo