[kdewebdev/quanta] fix deprecation warnings; make compatible with QT_NO_ASCII_CAST flag

git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdewebdev@1214823 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
v3.5.13-sru
samelian 14 years ago
parent af2166652d
commit 7af884d886

@ -62,7 +62,7 @@ KSaveSelectDialog::KSaveSelectDialog( KURL::List const & filelist, KURL::List co
_listview->header()->hide();
_listview->setResizeMode( TQListView::LastColumn );
setButtonOKText( i18n("Save &Selected"), i18n("Saves all selected files") );
setButtonOK( KGuiItem( i18n("Save &Selected"), TQString::null, i18n("Saves all selected files") ) );
setButtonText( User1, i18n("Save &None") );
setButtonText( Close, KStdGuiItem::cancel().text() );
setButtonTip( User1, i18n("Lose all modifications") );
@ -153,7 +153,7 @@ KSaveAllDialog::KSaveAllDialog( const TQStringList& filenames, TQWidget* parent
lb->setMinimumHeight( lb->fontMetrics().height() * 5 );
lb->insertStringList( filenames );
setButtonOKText( i18n("Save &All"), i18n("Saves all modified files") );
setButtonOK( KGuiItem( i18n("Save &All"), TQString::null, i18n("Saves all modified files") ) );
setButtonText( User1, i18n("Save &None") );
setButtonText( Close, KStdGuiItem::cancel().text() );
setButtonTip( User1, i18n("Lose all modifications") );

@ -48,7 +48,7 @@ TLPEditor::~TLPEditor(){
}
void TLPEditor::setButtonIcon(TQString s){
TQIconSet iconSet = SmallIconSet(TQString::fromLatin1(s));
TQIconSet iconSet = SmallIconSet(TQString::fromLatin1(s.ascii()));
TQPixmap pixMap = iconSet.pixmap( TQIconSet::Small, TQIconSet::Normal );
m_pb->setIconSet(iconSet);
m_pb->setFixedSize( pixMap.width()+8, pixMap.height()+8 );

@ -956,7 +956,7 @@ DebuggerVariable* QuantaDebuggerDBGp::buildVariable( const TQDomNode & variablen
}
else if (type == "string")
{
TQCString value = TQCString(variablenode.firstChild().nodeValue());
TQCString value = TQCString(variablenode.firstChild().nodeValue().ascii());
value = KCodecs::base64Decode(value);
return debuggerInterface()->newDebuggerVariable( name, value, DebuggerVariableTypes::String);
}

@ -341,8 +341,8 @@ void DebuggerManager::enableAction(const TQString& action, bool enable)
{
// The action may or may not exist, depending on capabilities of the debugger plugin
KActionCollection *ac = quantaApp->actionCollection();
if(ac && ac->action(action))
ac->action(action)->setEnabled(enable);
if(ac && ac->action(action.ascii()))
ac->action(action.ascii())->setEnabled(enable);
}
}

@ -443,7 +443,7 @@ void QuantaDebuggerGubed::processCommand(const TQString& datas)
else if(m_command == "status")
{
long argcnt = args["args"].toLong();
TQString msg = i18n(args["message"]); // How will we get these messages throught to the translators?
TQString msg = i18n(args["message"].ascii()); // How will we get these messages throught to the translators?
for(int cnt = 1; cnt <= argcnt; cnt++)
msg.replace("%" + TQString("%1").arg(cnt) + "%", args[TQString("arg%1").arg(cnt)]);
@ -604,15 +604,15 @@ bool QuantaDebuggerGubed::sendCommand(const TQString& command, StringMap args)
TQString buffer = phpSerialize(args);
buffer = TQString(command + ":%1;" + buffer).arg(buffer.length());
m_socket->writeBlock(buffer, buffer.length());
m_socket->writeBlock(buffer.ascii(), buffer.length());
return true;
}
// Send a command to gubed
bool QuantaDebuggerGubed::sendCommand(const TQString& command, char * firstarg, ...)
bool QuantaDebuggerGubed::sendCommand(const TQString& command, const char * firstarg, ...)
{
StringMap ca;
char *next;
const char *next;
va_list l_Arg;
va_start(l_Arg, firstarg);

@ -116,7 +116,7 @@ class QuantaDebuggerGubed : public DebuggerClient
// bool sendCommand(const TQString&, const TQString&);
bool sendCommand(const TQString& command, StringMap args);
bool sendCommand(const TQString& command, char * firstarg, ...);
bool sendCommand(const TQString& command, const char * firstarg, ...);
void processCommand(const TQString&);
void sendWatches();

@ -286,7 +286,7 @@ void VisualFrameEditor::removeNode(const TQString &l){
void VisualFrameEditor::drawGUI(treeNode *n, TQWidget* parent){
if(n->hasChildren()) {
TQString splitterName("splitter"+TQString::number(++splitterIdNumber,10));
TQSplitter *splitter = new TQSplitter(parent,splitterName);
TQSplitter *splitter = new TQSplitter(parent,splitterName.ascii());
if(SIZES.contains(splitterName)) splitter->setSizes( SIZES[splitterName] );
switch( n->splitType() ){
case VERTICAL : splitter->setOrientation(TQSplitter::Horizontal);break;
@ -300,7 +300,7 @@ void VisualFrameEditor::drawGUI(treeNode *n, TQWidget* parent){
}
}
else {
SelectableArea *sa=new SelectableArea(parent,n->label());
SelectableArea *sa=new SelectableArea(parent,n->label().ascii());
if(parent->isA("TQSplitter")) dynamic_cast<TQSplitter *>(parent)->setResizeMode(sa->view(),TQSplitter::KeepSize );
else
if(!m_firstInsertedSA) m_firstInsertedSA = sa;

@ -40,7 +40,7 @@ public:
typedef struct NestedTable{ Node *node; int row; int col; int bLine; int bCol; int eLine; int eCol; TQString nestedData;};
struct NestedTable { Node *node; int row; int col; int bLine; int bCol; int eLine; int eCol; TQString nestedData;};
class Parser;

@ -103,7 +103,7 @@ ActionConfigDialog::ActionConfigDialog(const TQDict<ToolbarEntry> &toolbarList,
{
if (node.nodeName() == "Action")
{
action = ac->action(node.toElement().attribute("name"));
action = ac->action(node.toElement().attribute("name").ascii());
if (action)
{
oldActionItem = new KListViewItem(item, oldActionItem, action->text().replace(r,""), action->shortcut().toString(), action->name());
@ -240,7 +240,7 @@ void ActionConfigDialog::slotEditToolbar()
{
if (node.nodeName() == "Action")
{
action = ac->action(node.toElement().attribute("name"));
action = ac->action(node.toElement().attribute("name").ascii());
if (action)
{
oldItem = new KListViewItem(item, oldItem, action->text().replace(TQRegExp("\\&(?!\\&)"),""), action->shortcut().toString(), action->name());

@ -27,7 +27,7 @@ class KPopupMenu;
class KShortcut;
class KXMLGUIClient;
typedef struct ToolbarEntry{
struct ToolbarEntry {
KXMLGUIClient *guiClient;
TQDomDocument *dom;
TQPopupMenu *menu;

@ -1422,7 +1422,7 @@ void Parser::parseIncludedFile(const TQString& fileName, const DTDStruct *dtd)
encoding = encodingIf->encoding();
if (encoding.isEmpty())
encoding = "utf8"; //final fallback
str.setCodec(TQTextCodec::codecForName(encoding));
str.setCodec(TQTextCodec::codecForName(encoding.ascii()));
content = str.read();
file.close();
if (dtd->specialAreas.count())

@ -37,7 +37,7 @@ class QTag;
class Node;
//an attribute of a tag looks like:
typedef struct Attribute{
struct Attribute {
TQString name;
TQString type; //"input", "check", "list"
TQStringList values; //the possible values it can have
@ -87,7 +87,7 @@ enum DTDFamily{Unknown = 0, Xml, Script};
#define MAX_STRUCTGROUPSCOUNT 10
//an internal representation of a DTD
typedef struct DTDStruct
struct DTDStruct
{
TQString name; ///< DTD name
TQString nickName; ///< DTD nickname

@ -408,7 +408,7 @@
<customwidgets>
<customwidget>
<class>DualEditableTree</class>
<header location="local">../../treeviews/tagattributetree.h</header>
<header location="local">tagattributetree.h</header>
<sizehint>
<width>250</width>
<height>100</height>

@ -2340,8 +2340,8 @@ Node* kafkaCommon::extractNode(Node *node, NodeModifsSet *modifs, bool extractCh
closingNamespaceName = next->tag->nameSpace;
closingNodeName = next->tag->name;
closingCaseSensitive = next->tag->dtd()->caseSensitive;
if(QuantaCommon::closesTag(namespaceName, nodeName, caseSensitive,
closingNamespaceName, closingNodeName, closingCaseSensitive))
if(QuantaCommon::closesTag(namespaceName, nodeName, !caseSensitive.isEmpty(),
closingNamespaceName, closingNodeName, !closingCaseSensitive.isEmpty()))
extractNode(next, modifs, false, false);
}
}

@ -129,7 +129,7 @@ void WHTMLPart::addToHistory(const TQString &url)
if ( !history.isEmpty() ) hpos++;
history.append(url);
history.append(url.ascii());
hpos = history.count()-1;

@ -73,7 +73,7 @@ void QuantaPlugin::setPluginName(const TQString &a_name)
m_name = a_name;
if (!m_action)
{
m_action = new KToggleAction(i18n(a_name.utf8()), 0, this, TQT_SLOT(toggle()), quantaApp->actionCollection(), a_name);
m_action = new KToggleAction(i18n(a_name.utf8()), 0, this, TQT_SLOT(toggle()), quantaApp->actionCollection(), a_name.ascii());
}
m_action->setText(a_name);
}
@ -124,8 +124,8 @@ bool QuantaPlugin::load()
m_targetWidget = 0L;
return false;
}
m_part->setName(m_name); // for better debug output
m_part->widget()->setName(m_name); //needed to be able to dock the same plugin twice in separate toolviews
m_part->setName(m_name.ascii()); // for better debug output
m_part->widget()->setName(m_name.ascii()); //needed to be able to dock the same plugin twice in separate toolviews
m_part->widget()->setFocusPolicy(TQWidget::ClickFocus);
quantaApp->slotNewPart(m_part, false); // register the part in the partmanager
return true;

@ -862,7 +862,7 @@ void Project::slotUpload()
if (!d->m_uploadDialog)
{
d->m_uploadDialog = new ProjectUpload(KURL(), "", false, false, false, i18n("Upload project items..."));
d->m_uploadDialog = new ProjectUpload(KURL(), "", false, false, false, i18n("Upload project items...").ascii());
connect(d->m_uploadDialog, TQT_SIGNAL(eventHappened(const TQString&, const TQString&, const TQString& )), this, TQT_SIGNAL(eventHappened(const TQString&, const TQString&, const TQString& )));
d->m_uploadDialog->show();
} else
@ -877,7 +877,7 @@ void Project::slotUploadURL(const KURL& urlToUpload, const TQString& profileName
KURL url = QExtFileInfo::toRelative( urlToUpload, d->baseURL);
if (!d->m_uploadDialog)
{
d->m_uploadDialog = new ProjectUpload(url, profileName, false, quickUpload, markOnly, i18n("Upload project items..."));
d->m_uploadDialog = new ProjectUpload(url, profileName, false, quickUpload, markOnly, i18n("Upload project items...").ascii());
connect(d->m_uploadDialog, TQT_SIGNAL(eventHappened(const TQString&, const TQString&, const TQString& )), this, TQT_SIGNAL(eventHappened(const TQString&, const TQString&, const TQString& )));
d->m_uploadDialog->show();
} else
@ -893,7 +893,7 @@ void Project::slotGetMessages(const TQString& data)
void Project::slotRescanPrjDir()
{
RescanPrj *dlg = new RescanPrj( d->m_projectFiles, d->baseURL, d->excludeRx,
d->m_mainWindow, i18n("New Files in Project's Folder"));
d->m_mainWindow, i18n("New Files in Project's Folder").ascii());
if ( dlg->exec() )
{
d->insertFiles(dlg->files());

@ -103,7 +103,7 @@ void ProjectNewWeb::slotStart()
{
if (baseURL.protocol() == "file")
{
chdir( baseURL.path(1));
chdir( baseURL.path(1).ascii() );
proc = new KProcess();
proc ->clearArguments();

@ -85,7 +85,7 @@ TQWidget * UploadProfiles::createTreeview(const UploadProfile &profile)
KURL kurl = url(profile.domElement);
if (kurl.isValid() && ! kurl.isEmpty())
{
widget = new ServerTreeView(quantaApp->config(), quantaApp, kurl, "ServerTreeView" + profile.name);
widget = new ServerTreeView(quantaApp->config(), quantaApp, kurl, TQString("ServerTreeView" + profile.name).ascii());
widget->setIcon(SmallIcon("up"));
widget->setCaption( i18n("Upload Profile") + ": " + profile.name );
quantaApp->addToolWindow(widget, quantaApp->prevDockPosition(widget, KDockWidget::DockRight), quantaApp->getMainDockWidget());

@ -164,7 +164,7 @@ Document::Document(KTextEditor::Document *doc,
m_encoding = encodingIf->encoding();
if (m_encoding.isEmpty())
m_encoding = "utf8"; //final fallback
m_codec = TQTextCodec::codecForName(m_encoding);
m_codec = TQTextCodec::codecForName(m_encoding.ascii());
selectionIf = dynamic_cast<KTextEditor::SelectionInterface *>(m_doc);
selectionIfExt = dynamic_cast<KTextEditor::SelectionInterfaceExt *>(m_doc);
@ -630,7 +630,7 @@ void Document::createTempFile()
encoding = encodingIf->encoding();
if (encoding.isEmpty())
encoding = "utf8"; //final fallback
tempFile->textStream()->setCodec(TQTextCodec::codecForName(encoding));
tempFile->textStream()->setCodec(TQTextCodec::codecForName(encoding.ascii()));
* (tempFile->textStream()) << editIf->text();
m_tempFileName = TQFileInfo(*(tempFile->file())).filePath();
@ -852,7 +852,7 @@ void Document::slotCharactersInserted(int line, int column, const TQString& stri
if (encoding != m_encoding)
{
m_encoding = encoding;
m_codec = TQTextCodec::codecForName(encoding);
m_codec = TQTextCodec::codecForName(encoding.ascii());
}
if (!m_codec->canEncode(string[0]))
{
@ -2708,7 +2708,7 @@ void Document::createBackup(KConfig* config)
if (file.open(IO_WriteOnly))
{
TQTextStream stream(&file);
stream.setCodec(TQTextCodec::codecForName(encoding));
stream.setCodec(TQTextCodec::codecForName(encoding.ascii()));
stream << editIf->text();
file.close();
}
@ -2870,7 +2870,7 @@ void Document::open(const KURL &url, const TQString &encoding)
{
encodingIf->setEncoding(encoding);
m_encoding = encoding;
m_codec = TQTextCodec::codecForName(m_encoding);
m_codec = TQTextCodec::codecForName(m_encoding.ascii());
}
connect(m_doc, TQT_SIGNAL(completed()), this, TQT_SLOT(slotOpeningCompleted()));
connect(m_doc, TQT_SIGNAL(canceled(const TQString&)), this, TQT_SLOT(slotOpeningFailed(const TQString&)));

@ -784,7 +784,7 @@ void DTDs::setAttributes(TQDomNode *dom, QTag* tag, bool &common)
tag->className = el.attribute("class", "");
tag->comment = el.attribute("comment", "");
if (!tag->comment.isEmpty())
tag->comment = " [" + i18n(tag->comment) + "] ";
tag->comment = " [" + i18n(tag->comment.ascii()) + "] ";
tag->comment.prepend(el.attribute("version"));
} else
{

@ -41,7 +41,7 @@ QuantaApp *quantaApp = 0L; //global pointer to the main application object
#define SPLASH_PICTURE "quantalogo"
KSplash::KSplash()
: TQFrame( 0L, TQString("Quanta")+QUANTA_VERSION,
: TQFrame( 0L, "Quanta" QUANTA_VERSION,
TQWidget::WStyle_NoBorder | TQWidget::WStyle_Customize | WX11BypassWM)
{
TQPixmap pm( UserIcon(SPLASH_PICTURE) );

@ -806,7 +806,7 @@ void QuantaApp::slotRepaintPreview()
encoding = encodingIf->encoding();
if (encoding.isEmpty())
encoding = "utf8"; //final fallback
tmpFile->textStream()->setCodec(TQTextCodec::codecForName(encoding));
tmpFile->textStream()->setCodec(TQTextCodec::codecForName(encoding.ascii()));
*(tmpFile->textStream()) << w->editIf->text();
tmpFile->close();
if (!QExtFileInfo::copy(KURL::fromPathOrURL(tempFileName), previewURL, -1, true)) {
@ -1018,7 +1018,7 @@ void QuantaApp::slotOptionsConfigureKeys()
{
if (node.nodeName() == "Action")
{
TagAction *action = dynamic_cast<TagAction*>(actionCollection()->action(node.toElement().attribute("name")));
TagAction *action = dynamic_cast<TagAction*>(actionCollection()->action(node.toElement().attribute("name").ascii()));
if (action)
{
action->setModified(true);
@ -1044,7 +1044,7 @@ void QuantaApp::slotConfigureToolbars(const TQString& defaultToolbar)
saveMainWindowSettings(KGlobal::config(), autoSaveGroup());
KEditToolbar *dlg;
if (defaultToolbar)
if (!defaultToolbar.isEmpty())
dlg = new KEditToolbar(defaultToolbar, factory(), this);
else
dlg = new KEditToolbar(factory(), this);
@ -1094,7 +1094,7 @@ void QuantaApp::slotConfigureToolbars(const TQString& defaultToolbar)
nodeList = p_toolbar->guiClient->domDocument().elementsByTagName("Action");
for (uint i = 0; i < nodeList.count(); i++)
{
KAction *action = ac->action(nodeList.item(i).toElement().attribute("name"));
KAction *action = ac->action(nodeList.item(i).toElement().attribute("name").ascii());
if (action)
action->plug(menu);
}
@ -1792,8 +1792,8 @@ TQWidget* QuantaApp::createContainer( TQWidget *parent, int index, const TQDomEl
//avoid TQToolBar warning in the log
QtMsgHandler oldHandler = qInstallMsgHandler( silenceQToolBar );
ToolbarTabWidget *toolbarTab = ToolbarTabWidget::ref();
TQWidget *w = new TQWidget(toolbarTab, "ToolbarHoldingWidget" + element.attribute("name"));
QuantaToolBar *tb = new QuantaToolBar(w, element.attribute("name"), true, true);
TQWidget *w = new TQWidget(toolbarTab, TQString("ToolbarHoldingWidget" + element.attribute("name")).ascii());
QuantaToolBar *tb = new QuantaToolBar(w, element.attribute("name").ascii(), true, true);
tb->loadState(element);
tb->setSizePolicy(TQSizePolicy::Preferred, TQSizePolicy::Minimum);
@ -2234,7 +2234,7 @@ void QuantaApp::slotLoadToolbarFile(const KURL& url)
el = node.toElement();
TQString actionName = el.attribute("name");
//if there is no such action yet, add to the available actions
if (!actionCollection()->action(actionName))
if (!actionCollection()->action(actionName.ascii()))
{
bool toggable = (el.attribute("toggable", "") == "true");
TagAction *tagAction = new TagAction(&el, this, toggable);
@ -2259,7 +2259,7 @@ void QuantaApp::slotLoadToolbarFile(const KURL& url)
} else
{
// kdDebug(24000) << "The action " << actionName << " is already present!" << endl;
TagAction *tagAction = dynamic_cast<TagAction*>(actionCollection()->action(actionName));
TagAction *tagAction = dynamic_cast<TagAction*>(actionCollection()->action(actionName.ascii()));
if (tagAction)
tagAction->setModified(true);
}
@ -2277,7 +2277,7 @@ void QuantaApp::slotLoadToolbarFile(const KURL& url)
nodeList = toolbarGUI->domDocument().elementsByTagName("Action");
for (uint i = 0; i < nodeList.count(); i++)
{
action = actionCollection()->action(nodeList.item(i).cloneNode().toElement().attribute("name") );
action = actionCollection()->action(nodeList.item(i).cloneNode().toElement().attribute("name").ascii() );
if (action)
{
action->plug(menu);
@ -2324,7 +2324,7 @@ void QuantaApp::showToolbarFile(const KURL &url)
nodeList = p_toolbar->guiClient->domDocument().elementsByTagName("Action");
for (uint i = 0; i < nodeList.count(); i++)
{
action = ac->action(nodeList.item(i).toElement().attribute("name") );
action = ac->action(nodeList.item(i).toElement().attribute("name").ascii() );
if (action)
{
action->plug(menu);
@ -2403,7 +2403,7 @@ KURL QuantaApp::saveToolbarToFile(const TQString& toolbarName, const KURL& destF
TQDomElement e = n.toElement();
if (e.tagName() == "Action")
{
TagAction *action = dynamic_cast<TagAction*>(actionCollection()->action(e.attribute("name")));
TagAction *action = dynamic_cast<TagAction*>(actionCollection()->action(e.attribute("name").ascii()));
if (action)
{
action->data().save(actStr,1);
@ -2735,7 +2735,7 @@ void QuantaApp::slotSendToolbar()
TQStringList toolbarFile;
toolbarFile += tempFileName;
TagMailDlg *mailDlg = new TagMailDlg( this, i18n("Send toolbar in email"));
TagMailDlg *mailDlg = new TagMailDlg( this, i18n("Send toolbar in email").ascii() );
TQString toStr;
TQString message = i18n("Hi,\n This is a Quanta Plus [http://quanta.kdewebdev.org] toolbar.\n\nHave fun.\n");
TQString titleStr;
@ -3285,7 +3285,7 @@ bool QuantaApp::slotRemoveToolbar(const TQString& a_name)
nodeList = toolbarGUI->domDocument().elementsByTagName("Action");
for (uint i = 0; i < nodeList.count(); i++)
{
action = actionCollection()->action(nodeList.item(i).toElement().attribute("name"));
action = actionCollection()->action(nodeList.item(i).toElement().attribute("name").ascii());
if (dynamic_cast<TagAction*>(action) &&
dynamic_cast<TagAction*>(action)->isModified())
{
@ -3377,7 +3377,7 @@ bool QuantaApp::slotRemoveToolbar(const TQString& a_name)
nodeList = p_toolbar->dom->elementsByTagName("Action");
for (uint i = 0; i < nodeList.count(); i++)
{
action = actionCollection()->action(nodeList.item(i).toElement().attribute("name"));
action = actionCollection()->action(nodeList.item(i).toElement().attribute("name").ascii());
if (action && !action->isPlugged())
{
if (dynamic_cast<TagAction*>(action) &&
@ -3609,7 +3609,7 @@ void QuantaApp::slotEmailDTEP()
TQStringList dtdFile;
dtdFile += tempFileName;
TagMailDlg *mailDlg = new TagMailDlg( this, i18n("Send DTEP in Email"));
TagMailDlg *mailDlg = new TagMailDlg( this, i18n("Send DTEP in Email").ascii());
TQString toStr;
TQString message = i18n("Hi,\n This is a Quanta Plus [http://quanta.kdewebdev.org] DTEP definition tarball.\n\nHave fun.\n");
TQString titleStr;
@ -4558,7 +4558,7 @@ void QuantaApp::slotTagMail()
Document *w = ViewManager::ref()->activeDocument();
if (!w) return;
TagMailDlg *mailDlg = new TagMailDlg( this, i18n("Email Link (mailto)"));
TagMailDlg *mailDlg = new TagMailDlg( this, i18n("Email Link (mailto)").ascii() );
if ( mailDlg->exec() ) {
TQString tag = TQString(QuantaCommon::tagCase("<a"));
@ -4620,7 +4620,7 @@ void QuantaApp::slotTagQuickList()
Document *w = ViewManager::ref()->activeDocument();
if (!w) return;
TagQuickListDlg *listDlg = new TagQuickListDlg(this,i18n("Generate List"));
TagQuickListDlg *listDlg = new TagQuickListDlg(this,i18n("Generate List").ascii());
if ( listDlg->exec() ) {
int i;
int n = listDlg->spinBoxRows->value();

@ -19,7 +19,7 @@
#define QUANTA_H
#define QUANTA_PACKAGE "quanta"
#define QUANTA_VERSION "3.5.10"
#define QUANTA_VERSION "3.5.13"
#define IDS_STATUS 1
#define IDS_INS_OVR 2
@ -95,8 +95,6 @@ class DebuggerManager;
class QuantaInit;
class KToolBarPopupAction;
class KTempFile;
class KParts::Part;
class KParts::PartManager;
namespace KTextEditor
{
class Mark;

@ -983,7 +983,7 @@ void QuantaInit::initActions()
TQDomElement e = n.toElement(); // try to convert the node to an element.
if( !e.isNull())
{ // the node was really an element.
delete ac->action(e.attribute("name"));
delete ac->action(e.attribute("name").ascii());
bool toggable = (e.attribute("toggable", "") == "true");
new TagAction(&e, m_quanta, toggable);
}

@ -268,7 +268,7 @@ void QuantaDoc::slotAttribPopup()
TQString name;
for (int i=0; i < tag->attrCount(); i++ )
attrList.append( tag->attribute(i) );
attrList.append( tag->attribute(i).ascii() );
if ( QuantaCommon::isKnownTag(w->getDTDIdentifier(),tagName) )
{
@ -281,7 +281,7 @@ void QuantaDoc::slotAttribPopup()
{
name = list->at(i)->name;
attribMenu->insertItem( name , i);//list->findIndex(*item) );
if (attrList.contains(name))
if (attrList.contains(name.ascii()))
{
attribMenu->setItemEnabled( i , false );
}
@ -297,7 +297,7 @@ void QuantaDoc::slotAttribPopup()
{
name = attrs->at(j)->name;
popUpMenu->insertItem(name, ++menuId);
if (attrList.contains(name))
if (attrList.contains(name.ascii()))
{
popUpMenu->setItemEnabled( menuId , false );
}

@ -437,7 +437,7 @@ FileInfoDlg* BaseTreeView::addFileInfoPage(KPropertiesDialog* propDlg)
TQFrame *quantaFilePage = propDlg->addPage(i18n("Quanta File Info"));
TQVBoxLayout *topLayout = new TQVBoxLayout( quantaFilePage);
quantaFileProperties = new FileInfoDlg( quantaFilePage, i18n("Quanta") );
quantaFileProperties = new FileInfoDlg( quantaFilePage, i18n("Quanta").ascii() );
int fsize,fimgsize=0;
int ct=0,imgct=0,position=0;

@ -188,7 +188,7 @@ ProjectTreeView::~ProjectTreeView(){
KFileTreeBranch* ProjectTreeView::newBranch(const KURL& url)
{
TQString m_projectNameStr = m_projectName+" ";
if (m_projectName)
if (!m_projectName.isEmpty())
{
if (url.protocol() == "file")
{
@ -212,7 +212,7 @@ KFileTreeBranch* ProjectTreeView::newBranch(const KURL& url)
this, TQT_SLOT(slotPopulateFinished(KFileTreeViewItem*)));
addBranch(m_projectDir);
m_projectDir->urlList = m_projectFiles; // set list for filter
if (m_projectName)
if (!m_projectName.isEmpty())
m_projectDir->populate(m_projectDir->rootUrl(), m_projectDir->root());
else
m_projectDir->root()->setEnabled(false);

@ -22,7 +22,6 @@
#include "basetreeview.h"
//#include "projecturl.h"
class KIO::Job;
class FileInfoDlg;
class ProjectList;

@ -43,7 +43,6 @@
#include <libxml/debugXML.h>
#include <libxml/HTMLtree.h>
#include <libxml/xmlIO.h>
#include <libxml/DOCBparser.h>
#include <libxml/xinclude.h>
#include <libxml/catalog.h>
#include <libxslt/xslt.h>
@ -270,7 +269,7 @@ void ScriptTreeView::slotSendScriptInMail()
TQStringList attachmentFile;
attachmentFile += createScriptTarball();
TagMailDlg *mailDlg = new TagMailDlg( this, i18n("Send script in email"));
TagMailDlg *mailDlg = new TagMailDlg( this, i18n("Send script in email").ascii() );
TQString toStr;
TQString message = i18n("Hi,\n This is a Quanta Plus [http://quanta.kdewebdev.org] script tarball.\n\nHave fun.\n");
TQString titleStr;

@ -461,17 +461,17 @@ EnhancedTagAttributeTree::EnhancedTagAttributeTree(TQWidget *parent, const char
attrTree->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::MinimumExpanding);
widgetLayout->addMultiCellWidget( attrTree, 1, 1, 0, 3 );
nodeName = new TQLabel(this, i18n( "Node Name" ));
nodeName = new TQLabel(this, i18n( "Node Name" ).ascii());
nodeName->setSizePolicy( TQSizePolicy( TQSizePolicy::MinimumExpanding, TQSizePolicy::Fixed, 0, 0, nodeName->sizePolicy().hasHeightForWidth() ) );
widgetLayout->addWidget( nodeName, 0, 0 );
deleteTag = new KPushButton(this, i18n( "Delete Tag" ));
deleteTag = new KPushButton(this, i18n( "Delete Tag" ).ascii());
deleteTag->setPixmap(SmallIcon("editdelete"));
deleteTag->setMaximumHeight(32);
deleteTag->setMaximumWidth(32);
TQToolTip::add(deleteTag, i18n("Delete the current tag only."));
deleteAll = new KPushButton(this, i18n( "Delete All" ));
deleteAll = new KPushButton(this, i18n( "Delete All" ).ascii());
deleteAll->setPixmap(SmallIcon("editdelete"));
deleteAll->setMaximumHeight(32);
deleteAll->setMaximumWidth(32);

@ -259,7 +259,7 @@ void TemplatesTreeView::slotMenu(KListView*, TQListViewItem *item, const TQPoint
return;
}
setSelected(item, true);
bool hasProject = m_projectName;
bool hasProject = !m_projectName.isEmpty();
m_folderMenu->setItemVisible(m_insertFolderInProject, hasProject);
m_fileMenu->setItemVisible(m_insertFileInProject, hasProject);
@ -373,7 +373,7 @@ void TemplatesTreeView::slotOpen()
/** No descriptions */
void TemplatesTreeView::slotNewDir()
{
NewTemplateDirDlg *createDirDlg = new NewTemplateDirDlg(this,i18n("Create New Template Folder"));
NewTemplateDirDlg *createDirDlg = new NewTemplateDirDlg(this,i18n("Create New Template Folder").ascii());
createDirDlg->typesCombo->insertItem(typeToi18n["text/all"]);
createDirDlg->typesCombo->insertItem(typeToi18n["file/all"]);
createDirDlg->typesCombo->insertItem(typeToi18n["template/all"]);
@ -564,7 +564,7 @@ void TemplatesTreeView::slotProperties()
//Always add the Quanta directory page
TQFrame *quantaDirPage = propDlg->addPage(i18n("Quanta Template"));
TQVBoxLayout *topLayout = new TQVBoxLayout( quantaDirPage);
m_quantaProperties = new QuantaPropertiesPage( quantaDirPage, i18n("Quanta") );
m_quantaProperties = new QuantaPropertiesPage( quantaDirPage, i18n("Quanta").ascii() );
m_quantaProperties->typesCombo->insertItem(typeToi18n["text/all"]);
m_quantaProperties->typesCombo->insertItem(typeToi18n["file/all"]);
@ -982,7 +982,7 @@ void TemplatesTreeView::slotSendInMail()
TQStringList attachmentFile;
attachmentFile += createTemplateTarball();
TagMailDlg *mailDlg = new TagMailDlg( this, i18n("Send template in email"));
TagMailDlg *mailDlg = new TagMailDlg( this, i18n("Send template in email").ascii() );
TQString toStr;
TQString message = i18n("Hi,\n This is a Quanta Plus [http://quanta.kdewebdev.org] template tarball.\n\nHave fun.\n");
TQString titleStr;

@ -321,7 +321,7 @@ bool QPEvents::handleEvent(const EventAction& ev)
if (ev.action == "script" || ev.action =="action")
{
TQString name = ev.arguments[0];
KAction *action = quantaApp->actionCollection()->action(name);
KAction *action = quantaApp->actionCollection()->action(name.ascii());
TagAction *tagAction = dynamic_cast<TagAction*>(action);
if (tagAction)
{

@ -104,7 +104,7 @@ public:
bool smartTagInsertion; //enable/disable smartTagInsertion
};
typedef struct DirInfo{
struct DirInfo {
TQString mimeType;
TQString preText;
TQString postText;

@ -74,7 +74,7 @@ int MyProcess::commSetupDoneC()
TagAction::TagAction( TQDomElement *element, KMainWindow *parentMainWindow, bool toggle)
: KToggleAction(element->attribute("text").isEmpty() ? TQString("") : i18n(element->attribute("text").utf8()),
KShortcut(element->attribute("shortcut")), 0, 0, parentMainWindow->actionCollection(), element->attribute("name")),
KShortcut(element->attribute("shortcut")), 0, 0, parentMainWindow->actionCollection(), element->attribute("name").ascii()),
//disable toggle now m_toggle(toggle)
m_toggle(false)
{

@ -100,7 +100,7 @@ void TagActionSet::initActions(TQWidget* /*parent*/)
{
KActionCollection* ac(TagActionManager::self()->actionCollection());
TQString actionName = "apply_source_indentation";
const char *actionName = "apply_source_indentation";
new KAction(i18n("Apply Source Indentation"), 0, this,
TQT_SLOT(slotApplySourceIndentation()),
ac, actionName);
@ -296,7 +296,7 @@ void TableTagActionSet::initActions(TQWidget* parent)
// Insert___________________________________________________________________________
TQString actionName = "insert_table";
const char *actionName = "insert_table";
//m_actionNames += actionName;
new KAction(i18n("Table..."), 0, this,
TQT_SLOT(slotInsertTable()),

Loading…
Cancel
Save