X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fuisupport%2Fbufferview.h;h=1ea2fdf97dfc2ec03f7ac69025dc3ec2c19660cc;hp=ce45c5b5f17d1375c50c38f4a7c2f04a22d1c6c3;hb=35ca85f1c4371ee28d00d5ff0195a5b44aadb299;hpb=19740eba83b9d776d8f62cae02762ee3b08e3b67 diff --git a/src/uisupport/bufferview.h b/src/uisupport/bufferview.h index ce45c5b5..1ea2fdf9 100644 --- a/src/uisupport/bufferview.h +++ b/src/uisupport/bufferview.h @@ -1,5 +1,5 @@ /*************************************************************************** - * Copyright (C) 2005-2015 by the Quassel Project * + * Copyright (C) 2005-2018 by the Quassel Project * * devel@quassel-irc.org * * * * This program is free software; you can redistribute it and/or modify * @@ -26,14 +26,13 @@ #include #include #include -#include #include #include "actioncollection.h" #include "bufferviewconfig.h" #include "networkmodel.h" -#include "types.h" #include "treeviewtouch.h" +#include "types.h" /***************************************** * The TreeView showing the Buffers @@ -91,7 +90,31 @@ private slots: void joinChannel(const QModelIndex &index); void toggleHeader(bool checked); + /** + * Expand all active networks and collapse inactive ones unless manually changed + * + * Applies to all networks. Shouldn't need called except during initialization. + */ + void setExpandedState(); + + /** + * Save the current display state of the given network + * + * Tracks expanded or collapsed and active or inactive. + * + * @see setExpandedState() + * @param[in] networkIdx QModelIndex of the root network to store + */ void storeExpandedState(const QModelIndex &networkIdx); + + /** + * Set the display state of the given network according to network status and manual changes + * + * Expands if active or previously expanded, collapses if inactive or previously collapsed. + * + * @see storeExpandedState() + * @param[in] networkIdx QModelIndex of the root network to update + */ void setExpandedState(const QModelIndex &networkIdx); void on_configChanged();