]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Add clearTooltip function
authorterencehill <piuntn@gmail.com>
Sun, 30 Aug 2015 18:17:56 +0000 (20:17 +0200)
committerterencehill <piuntn@gmail.com>
Sun, 30 Aug 2015 18:17:56 +0000 (20:17 +0200)
qcsrc/menu/xonotic/serverlist.qc
qcsrc/menu/xonotic/util.qc
qcsrc/menu/xonotic/util.qh

index 41e11e383b77d6b090d58c5983a5a3d9ea708f86..f49ea947e73bb7dd8601718453a75cd152b3a1f4 100644 (file)
@@ -437,7 +437,7 @@ void ServerList_Update_favoriteButton(entity btn, entity me)
        if(IsFavorite(me.ipAddressBox.text))
        {
                e.setText(e, _("Remove"));
-               setZonedTooltip(e, string_null, string_null);
+               clearTooltip(e);
        }
        else
        {
index 2554759f3ce35422a997d1ef2aad201b974d1932..56c816dab93842338cdf4ca1be0ee6967e305d0e 100644 (file)
@@ -38,6 +38,11 @@ void setZonedTooltip(entity e, string theTooltip, string theCvar)
        e.tooltip = (theTooltip != "") ? strzone(theTooltip) : string_null;
 }
 
+void clearTooltip(entity e)
+{
+       setZonedTooltip(e, string_null, string_null);
+}
+
 .entity parent, firstChild, nextSibling;
 void forAllDescendants(entity root, void(entity, entity) funcPre, void(entity, entity) funcPost, entity pass)
 {
index 2ee8a4d03ea563cf52bb6a2481c2939f0dbe611a..9e989a4662070fea39b6ae7a8934dd2f1109f00a 100644 (file)
@@ -20,6 +20,7 @@ void setDependentStringNotEqual(entity e, string theCvarName, string theCvarValu
 void setDependentWeird(entity e, float(entity) func);
 
 void setZonedTooltip(entity e, string theTooltip, string theCvar);
+void clearTooltip(entity e);
 
 string resolvemod(string m);