dmz::V8Value
dmz::JsModuleUiV8QtBasic::_list_widget_take_item (const v8::Arguments &Args) {

   v8::HandleScope scope;
   V8Value result = v8::Undefined ();

   JsModuleUiV8QtBasic *self = _to_self (Args);
   if (self) {

      QListWidget *lw = self->v8_to_qobject<QListWidget> (Args.This ());
      if (lw) {

         if (Args.Length ()) {

            QListWidgetItem *item = self->_to_qlistwidgetitem (Args[0]);
            if (item) {

               item = lw->takeItem (lw->row (item));
               if (item) {

                  result = self->create_v8_qlistwidgetitem (item);
               }
            }
         }
      }
   }

   return scope.Close (result);
}
dmz::V8Value
dmz::JsModuleUiV8QtBasic::_list_widget_item_text (const v8::Arguments &Args) {

   v8::HandleScope scope;
   V8Value result = v8::Undefined ();

   JsModuleUiV8QtBasic *self = _to_self (Args);
   if (self) {

      QListWidgetItem *item = self->_to_qlistwidgetitem (Args.This ());
      if (item) {

         if (Args.Length ()) {

            item->setText (v8_to_qstring (Args[0]));
         }

         result = qstring_to_v8 (item->text ());
      }
   }

   return scope.Close (result);
}
dmz::V8Value
dmz::JsModuleUiV8QtBasic::_list_widget_item_data (const v8::Arguments &Args) {

   v8::HandleScope scope;
   V8Value result = v8::Undefined ();

   JsModuleUiV8QtBasic *self = _to_self (Args);
   if (self) {

      QListWidgetItem *item = self->_to_qlistwidgetitem (Args.This ());
      if (item) {

         if (Args.Length ()) {

            QVariant variant = self->_qvariant_wrap_v8 (Args[0]);
            item->setData (Qt::UserRole, variant);
         }

         result = self->_qvariant_unwrap_v8 (item->data (Qt::UserRole));
      }
   }

   return scope.Close (result);
}