// Generated by gmmproc 2.55.1 -- DO NOT MODIFY!


#include <glibmm.h>

#include <giomm/propertyaction.h>
#include <giomm/private/propertyaction_p.h>


/* Copyright (C) 2017 The giomm Development Team
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library. If not, see <http://www.gnu.org/licenses/>.
 */

#include <gio/gio.h>

namespace Gio
{

PropertyAction::PropertyAction(const Glib::ustring& name,
  const Glib::PropertyProxy_Base& property_proxy, bool invert_boolean)
:
// Mark this class as non-derived to allow C++ vfuncs to be skipped.
  Glib::ObjectBase(nullptr),
  Glib::Object(Glib::ConstructParams(propertyaction_class_.init(), "name",name.c_str(),"object",property_proxy.get_object()->gobj(),"property-name",property_proxy.get_name(),"invert-boolean",invert_boolean, nullptr))
{
}

} // namespace Gio

namespace
{
} // anonymous namespace


namespace Glib
{

Glib::RefPtr<Gio::PropertyAction> wrap(GPropertyAction* object, bool take_copy)
{
  return Glib::make_refptr_for_instance<Gio::PropertyAction>( dynamic_cast<Gio::PropertyAction*> (Glib::wrap_auto ((GObject*)(object), take_copy)) );
  //We use dynamic_cast<> in case of multiple inheritance.
}

} /* namespace Glib */


namespace Gio
{


/* The *_Class implementation: */

const Glib::Class& PropertyAction_Class::init()
{
  if(!gtype_) // create the GType if necessary
  {
    // Glib::Class has to know the class init function to clone custom types.
    class_init_func_ = &PropertyAction_Class::class_init_function;

    // This is actually just optimized away, apparently with no harm.
    // Make sure that the parent type has been created.
    //CppClassParent::CppObjectType::get_type();

    // Create the wrapper type, with the same class/instance size as the base type.
    register_derived_type(g_property_action_get_type());

    // Add derived versions of interfaces, if the C type implements any interfaces:
  Action::add_interface(get_type());

  }

  return *this;
}


void PropertyAction_Class::class_init_function(void* g_class, void* class_data)
{
  const auto klass = static_cast<BaseClassType*>(g_class);
  CppClassParent::class_init_function(klass, class_data);


}


Glib::ObjectBase* PropertyAction_Class::wrap_new(GObject* object)
{
  return new PropertyAction((GPropertyAction*)object);
}


/* The implementation: */

GPropertyAction* PropertyAction::gobj_copy()
{
  reference();
  return gobj();
}

PropertyAction::PropertyAction(const Glib::ConstructParams& construct_params)
:
  Glib::Object(construct_params)
{

}

PropertyAction::PropertyAction(GPropertyAction* castitem)
:
  Glib::Object((GObject*)(castitem))
{}


PropertyAction::PropertyAction(PropertyAction&& src) noexcept
: Glib::Object(std::move(src))
  , Action(std::move(src))
{}

PropertyAction& PropertyAction::operator=(PropertyAction&& src) noexcept
{
  Glib::Object::operator=(std::move(src));
  Action::operator=(std::move(src));
  return *this;
}


PropertyAction::~PropertyAction() noexcept
{}


PropertyAction::CppClassType PropertyAction::propertyaction_class_; // initialize static member

GType PropertyAction::get_type()
{
  return propertyaction_class_.init().get_type();
}


GType PropertyAction::get_base_type()
{
  return g_property_action_get_type();
}


Glib::RefPtr<PropertyAction> PropertyAction::create(const Glib::ustring& name, const Glib::PropertyProxy_Base& property_proxy, bool invert_boolean)
{
  return Glib::make_refptr_for_instance<PropertyAction>( new PropertyAction(name, property_proxy, invert_boolean) );
}


Glib::PropertyProxy_ReadOnly< Glib::ustring > PropertyAction::property_name() const
{
  return Glib::PropertyProxy_ReadOnly< Glib::ustring >(this, "name");
}

Glib::PropertyProxy_ReadOnly< Glib::VariantType > PropertyAction::property_parameter_type() const
{
  return Glib::PropertyProxy_ReadOnly< Glib::VariantType >(this, "parameter-type");
}

Glib::PropertyProxy_ReadOnly< bool > PropertyAction::property_enabled() const
{
  return Glib::PropertyProxy_ReadOnly< bool >(this, "enabled");
}

Glib::PropertyProxy_ReadOnly< Glib::VariantType > PropertyAction::property_state_type() const
{
  return Glib::PropertyProxy_ReadOnly< Glib::VariantType >(this, "state-type");
}

Glib::PropertyProxy_ReadOnly< Glib::VariantBase > PropertyAction::property_state() const
{
  return Glib::PropertyProxy_ReadOnly< Glib::VariantBase >(this, "state");
}

Glib::PropertyProxy_ReadOnly< bool > PropertyAction::property_invert_boolean() const
{
  return Glib::PropertyProxy_ReadOnly< bool >(this, "invert-boolean");
}


} // namespace Gio


