* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ * along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
-#ifndef PULSEVIEW_PV_BINDING_BINDING_H
-#define PULSEVIEW_PV_BINDING_BINDING_H
+#ifndef PULSEVIEW_PV_BINDING_BINDING_HPP
+#define PULSEVIEW_PV_BINDING_BINDING_HPP
+#include <glib.h>
+// Suppress warnings due to use of deprecated std::auto_ptr<> by glibmm.
+G_GNUC_BEGIN_IGNORE_DEPRECATIONS
#include <glibmm.h>
+G_GNUC_END_IGNORE_DEPRECATIONS
-#include <vector>
#include <memory>
+#include <vector>
#include <QString>
+using std::shared_ptr;
+using std::vector;
+
class QFormLayout;
class QWidget;
class Binding
{
public:
- const std::vector< std::shared_ptr<prop::Property> >& properties();
+ const vector< shared_ptr<prop::Property> >& properties();
void commit();
QWidget* get_property_form(QWidget *parent,
bool auto_commit = false) const;
+ void update_property_widgets();
+
static QString print_gvariant(Glib::VariantBase gvar);
protected:
- std::vector< std::shared_ptr<prop::Property> > properties_;
+ vector< shared_ptr<prop::Property> > properties_;
};
-} // binding
-} // pv
+} // namespace binding
+} // namespace pv
-#endif // PULSEVIEW_PV_BINDING_BINDING_H
+#endif // PULSEVIEW_PV_BINDING_BINDING_HPP