@ -32,7 +32,7 @@
# include <dom/dom_element.h>
# include <dom/dom_string.h>
# include <dom/html_document.h>
# include < k action.h>
# include < tde action.h>
# include <kdebug.h>
# include <kgenericfactory.h>
# include <tdehtml_part.h>
@ -40,9 +40,9 @@
# include <kiconloader.h>
# include <kinstance.h>
# include <klocale.h>
# include < k popupmenu.h>
# include < k shortcut.h>
# include < k toolbar.h>
# include < tde popupmenu.h>
# include < tde shortcut.h>
# include < tde toolbar.h>
# include <kurl.h>
// local includes
@ -70,106 +70,106 @@ RelLinksPlugin::RelLinksPlugin(TQObject *parent, const char *name, const TQStrin
setInstance ( RelLinksFactory : : instance ( ) ) ;
// ------------- Navigation links --------------
k action_map[ " home " ] = new TDEAction ( i18n ( " &Top " ) , " 2uparrow " , TDEShortcut ( " Ctrl+Alt+T " ) , this , TQT_SLOT ( goHome ( ) ) , actionCollection ( ) , " rellinks_top " ) ;
k action_map[ " home " ] - > setWhatsThis ( i18n ( " <p>This link references a home page or the top of some hierarchy.</p> " ) ) ;
tde action_map[ " home " ] = new TDEAction ( i18n ( " &Top " ) , " 2uparrow " , TDEShortcut ( " Ctrl+Alt+T " ) , this , TQT_SLOT ( goHome ( ) ) , actionCollection ( ) , " rellinks_top " ) ;
tde action_map[ " home " ] - > setWhatsThis ( i18n ( " <p>This link references a home page or the top of some hierarchy.</p> " ) ) ;
k action_map[ " up " ] = new TDEAction ( i18n ( " &Up " ) , " 1uparrow " , TDEShortcut ( " Ctrl+Alt+U " ) , this , TQT_SLOT ( goUp ( ) ) , actionCollection ( ) , " rellinks_up " ) ;
k action_map[ " up " ] - > setWhatsThis ( i18n ( " <p>This link references the immediate parent of the current document.</p> " ) ) ;
tde action_map[ " up " ] = new TDEAction ( i18n ( " &Up " ) , " 1uparrow " , TDEShortcut ( " Ctrl+Alt+U " ) , this , TQT_SLOT ( goUp ( ) ) , actionCollection ( ) , " rellinks_up " ) ;
tde action_map[ " up " ] - > setWhatsThis ( i18n ( " <p>This link references the immediate parent of the current document.</p> " ) ) ;
bool isRTL = TQApplication : : reverseLayout ( ) ;
k action_map[ " begin " ] = new TDEAction ( i18n ( " &First " ) , isRTL ? " 2rightarrow " : " 2leftarrow " , TDEShortcut ( " Ctrl+Alt+F " ) , this , TQT_SLOT ( goFirst ( ) ) , actionCollection ( ) , " rellinks_first " ) ;
k action_map[ " begin " ] - > setWhatsThis ( i18n ( " <p>This link type tells search engines which document is considered by the author to be the starting point of the collection.</p> " ) ) ;
tde action_map[ " begin " ] = new TDEAction ( i18n ( " &First " ) , isRTL ? " 2rightarrow " : " 2leftarrow " , TDEShortcut ( " Ctrl+Alt+F " ) , this , TQT_SLOT ( goFirst ( ) ) , actionCollection ( ) , " rellinks_first " ) ;
tde action_map[ " begin " ] - > setWhatsThis ( i18n ( " <p>This link type tells search engines which document is considered by the author to be the starting point of the collection.</p> " ) ) ;
k action_map[ " prev " ] = new TDEAction ( i18n ( " &Previous " ) , isRTL ? " 1rightarrow " : " 1leftarrow " , TDEShortcut ( " Ctrl+Alt+P " ) , this , TQT_SLOT ( goPrevious ( ) ) , actionCollection ( ) , " rellinks_previous " ) ;
k action_map[ " prev " ] - > setWhatsThis ( i18n ( " <p>This link references the previous document in an ordered series of documents.</p> " ) ) ;
tde action_map[ " prev " ] = new TDEAction ( i18n ( " &Previous " ) , isRTL ? " 1rightarrow " : " 1leftarrow " , TDEShortcut ( " Ctrl+Alt+P " ) , this , TQT_SLOT ( goPrevious ( ) ) , actionCollection ( ) , " rellinks_previous " ) ;
tde action_map[ " prev " ] - > setWhatsThis ( i18n ( " <p>This link references the previous document in an ordered series of documents.</p> " ) ) ;
k action_map[ " next " ] = new TDEAction ( i18n ( " &Next " ) , isRTL ? " 1leftarrow " : " 1rightarrow " , TDEShortcut ( " Ctrl+Alt+N " ) , this , TQT_SLOT ( goNext ( ) ) , actionCollection ( ) , " rellinks_next " ) ;
k action_map[ " next " ] - > setWhatsThis ( i18n ( " <p>This link references the next document in an ordered series of documents.</p> " ) ) ;
tde action_map[ " next " ] = new TDEAction ( i18n ( " &Next " ) , isRTL ? " 1leftarrow " : " 1rightarrow " , TDEShortcut ( " Ctrl+Alt+N " ) , this , TQT_SLOT ( goNext ( ) ) , actionCollection ( ) , " rellinks_next " ) ;
tde action_map[ " next " ] - > setWhatsThis ( i18n ( " <p>This link references the next document in an ordered series of documents.</p> " ) ) ;
k action_map[ " last " ] = new TDEAction ( i18n ( " &Last " ) , isRTL ? " 2leftarrow " : " 2rightarrow " , TDEShortcut ( " Ctrl+Alt+L " ) , this , TQT_SLOT ( goLast ( ) ) , actionCollection ( ) , " rellinks_last " ) ;
k action_map[ " last " ] - > setWhatsThis ( i18n ( " <p>This link references the end of a sequence of documents.</p> " ) ) ;
tde action_map[ " last " ] = new TDEAction ( i18n ( " &Last " ) , isRTL ? " 2leftarrow " : " 2rightarrow " , TDEShortcut ( " Ctrl+Alt+L " ) , this , TQT_SLOT ( goLast ( ) ) , actionCollection ( ) , " rellinks_last " ) ;
tde action_map[ " last " ] - > setWhatsThis ( i18n ( " <p>This link references the end of a sequence of documents.</p> " ) ) ;
// ------------ special items --------------------------
k action_map[ " search " ] = new TDEAction ( i18n ( " &Search " ) , " filefind " , TDEShortcut ( " Ctrl+Alt+S " ) , this , TQT_SLOT ( goSearch ( ) ) , actionCollection ( ) , " rellinks_search " ) ;
k action_map[ " search " ] - > setWhatsThis ( i18n ( " <p>This link references the search.</p> " ) ) ;
tde action_map[ " search " ] = new TDEAction ( i18n ( " &Search " ) , " filefind " , TDEShortcut ( " Ctrl+Alt+S " ) , this , TQT_SLOT ( goSearch ( ) ) , actionCollection ( ) , " rellinks_search " ) ;
tde action_map[ " search " ] - > setWhatsThis ( i18n ( " <p>This link references the search.</p> " ) ) ;
// ------------ Document structure links ---------------
m_document = new TDEActionMenu ( i18n ( " Document " ) , " contents " , actionCollection ( ) , " rellinks_document " ) ;
m_document - > setWhatsThis ( i18n ( " <p>This menu contains the links referring the document information.</p> " ) ) ;
m_document - > setDelayed ( false ) ;
k action_map[ " contents " ] = new TDEAction ( i18n ( " Table of &Contents " ) , " contents " , TDEShortcut ( " Ctrl+Alt+C " ) , this , TQT_SLOT ( goContents ( ) ) , actionCollection ( ) , " rellinks_toc " ) ;
m_document - > insert ( k action_map[ " contents " ] ) ;
k action_map[ " contents " ] - > setWhatsThis ( i18n ( " <p>This link references the table of contents.</p> " ) ) ;
k actionmenu_map[ " chapter " ] = new TDEActionMenu ( i18n ( " Chapters " ) , " fileopen " , actionCollection ( ) , " rellinks_chapters " ) ;
m_document - > insert ( k actionmenu_map[ " chapter " ] ) ;
connect ( k actionmenu_map[ " chapter " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goChapter ( int ) ) ) ;
k actionmenu_map[ " chapter " ] - > setWhatsThis ( i18n ( " <p>This menu references the chapters of the document.</p> " ) ) ;
k actionmenu_map[ " chapter " ] - > setDelayed ( false ) ;
k actionmenu_map[ " section " ] = new TDEActionMenu ( i18n ( " Sections " ) , " fileopen " , actionCollection ( ) , " rellinks_sections " ) ;
m_document - > insert ( k actionmenu_map[ " section " ] ) ;
connect ( k actionmenu_map[ " section " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goSection ( int ) ) ) ;
k actionmenu_map[ " section " ] - > setWhatsThis ( i18n ( " <p>This menu references the sections of the document.</p> " ) ) ;
k actionmenu_map[ " section " ] - > setDelayed ( false ) ;
k actionmenu_map[ " subsection " ] = new TDEActionMenu ( i18n ( " Subsections " ) , " fileopen " , actionCollection ( ) , " rellinks_subsections " ) ;
m_document - > insert ( k actionmenu_map[ " subsection " ] ) ;
connect ( k actionmenu_map[ " subsection " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goSubsection ( int ) ) ) ;
k actionmenu_map[ " subsection " ] - > setWhatsThis ( i18n ( " <p>This menu references the subsections of the document.</p> " ) ) ;
k actionmenu_map[ " subsection " ] - > setDelayed ( false ) ;
k actionmenu_map[ " appendix " ] = new TDEActionMenu ( i18n ( " Appendix " ) , " edit " , actionCollection ( ) , " rellinks_appendix " ) ;
m_document - > insert ( k actionmenu_map[ " appendix " ] ) ;
connect ( k actionmenu_map[ " appendix " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goAppendix ( int ) ) ) ;
k actionmenu_map[ " appendix " ] - > setWhatsThis ( i18n ( " <p>This link references the appendix.</p> " ) ) ;
k actionmenu_map[ " appendix " ] - > setDelayed ( false ) ;
k action_map[ " glossary " ] = new TDEAction ( i18n ( " &Glossary " ) , " flag " , TDEShortcut ( " Ctrl+Alt+G " ) , this , TQT_SLOT ( goGlossary ( ) ) , actionCollection ( ) , " rellinks_glossary " ) ;
m_document - > insert ( k action_map[ " glossary " ] ) ;
k action_map[ " glossary " ] - > setWhatsThis ( i18n ( " <p>This link references the glossary.</p> " ) ) ;
k action_map[ " index " ] = new TDEAction ( i18n ( " &Index " ) , " info " , TDEShortcut ( " Ctrl+Alt+I " ) , this , TQT_SLOT ( goIndex ( ) ) , actionCollection ( ) , " rellinks_index " ) ;
m_document - > insert ( k action_map[ " index " ] ) ;
k action_map[ " index " ] - > setWhatsThis ( i18n ( " <p>This link references the index.</p> " ) ) ;
tde action_map[ " contents " ] = new TDEAction ( i18n ( " Table of &Contents " ) , " contents " , TDEShortcut ( " Ctrl+Alt+C " ) , this , TQT_SLOT ( goContents ( ) ) , actionCollection ( ) , " rellinks_toc " ) ;
m_document - > insert ( tde action_map[ " contents " ] ) ;
tde action_map[ " contents " ] - > setWhatsThis ( i18n ( " <p>This link references the table of contents.</p> " ) ) ;
tde actionmenu_map[ " chapter " ] = new TDEActionMenu ( i18n ( " Chapters " ) , " fileopen " , actionCollection ( ) , " rellinks_chapters " ) ;
m_document - > insert ( tde actionmenu_map[ " chapter " ] ) ;
connect ( tde actionmenu_map[ " chapter " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goChapter ( int ) ) ) ;
tde actionmenu_map[ " chapter " ] - > setWhatsThis ( i18n ( " <p>This menu references the chapters of the document.</p> " ) ) ;
tde actionmenu_map[ " chapter " ] - > setDelayed ( false ) ;
tde actionmenu_map[ " section " ] = new TDEActionMenu ( i18n ( " Sections " ) , " fileopen " , actionCollection ( ) , " rellinks_sections " ) ;
m_document - > insert ( tde actionmenu_map[ " section " ] ) ;
connect ( tde actionmenu_map[ " section " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goSection ( int ) ) ) ;
tde actionmenu_map[ " section " ] - > setWhatsThis ( i18n ( " <p>This menu references the sections of the document.</p> " ) ) ;
tde actionmenu_map[ " section " ] - > setDelayed ( false ) ;
tde actionmenu_map[ " subsection " ] = new TDEActionMenu ( i18n ( " Subsections " ) , " fileopen " , actionCollection ( ) , " rellinks_subsections " ) ;
m_document - > insert ( tde actionmenu_map[ " subsection " ] ) ;
connect ( tde actionmenu_map[ " subsection " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goSubsection ( int ) ) ) ;
tde actionmenu_map[ " subsection " ] - > setWhatsThis ( i18n ( " <p>This menu references the subsections of the document.</p> " ) ) ;
tde actionmenu_map[ " subsection " ] - > setDelayed ( false ) ;
tde actionmenu_map[ " appendix " ] = new TDEActionMenu ( i18n ( " Appendix " ) , " edit " , actionCollection ( ) , " rellinks_appendix " ) ;
m_document - > insert ( tde actionmenu_map[ " appendix " ] ) ;
connect ( tde actionmenu_map[ " appendix " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goAppendix ( int ) ) ) ;
tde actionmenu_map[ " appendix " ] - > setWhatsThis ( i18n ( " <p>This link references the appendix.</p> " ) ) ;
tde actionmenu_map[ " appendix " ] - > setDelayed ( false ) ;
tde action_map[ " glossary " ] = new TDEAction ( i18n ( " &Glossary " ) , " flag " , TDEShortcut ( " Ctrl+Alt+G " ) , this , TQT_SLOT ( goGlossary ( ) ) , actionCollection ( ) , " rellinks_glossary " ) ;
m_document - > insert ( tde action_map[ " glossary " ] ) ;
tde action_map[ " glossary " ] - > setWhatsThis ( i18n ( " <p>This link references the glossary.</p> " ) ) ;
tde action_map[ " index " ] = new TDEAction ( i18n ( " &Index " ) , " info " , TDEShortcut ( " Ctrl+Alt+I " ) , this , TQT_SLOT ( goIndex ( ) ) , actionCollection ( ) , " rellinks_index " ) ;
m_document - > insert ( tde action_map[ " index " ] ) ;
tde action_map[ " index " ] - > setWhatsThis ( i18n ( " <p>This link references the index.</p> " ) ) ;
// Other links
m_more = new TDEActionMenu ( i18n ( " More " ) , " misc " , actionCollection ( ) , " rellinks_more " ) ;
m_more - > setWhatsThis ( i18n ( " <p>This menu contains other important links.</p> " ) ) ;
m_more - > setDelayed ( false ) ;
k action_map[ " help " ] = new TDEAction ( i18n ( " &Help " ) , " help " , TDEShortcut ( " Ctrl+Alt+H " ) , this , TQT_SLOT ( goHelp ( ) ) , actionCollection ( ) , " rellinks_help " ) ;
m_more - > insert ( k action_map[ " help " ] ) ;
k action_map[ " help " ] - > setWhatsThis ( i18n ( " <p>This link references the help.</p> " ) ) ;
tde action_map[ " help " ] = new TDEAction ( i18n ( " &Help " ) , " help " , TDEShortcut ( " Ctrl+Alt+H " ) , this , TQT_SLOT ( goHelp ( ) ) , actionCollection ( ) , " rellinks_help " ) ;
m_more - > insert ( tde action_map[ " help " ] ) ;
tde action_map[ " help " ] - > setWhatsThis ( i18n ( " <p>This link references the help.</p> " ) ) ;
k action_map[ " author " ] = new TDEAction ( i18n ( " &Authors " ) , " mail_new " , TDEShortcut ( " Ctrl+Alt+A " ) , this , TQT_SLOT ( goAuthor ( ) ) , actionCollection ( ) , " rellinks_authors " ) ;
m_more - > insert ( k action_map[ " author " ] ) ;
k action_map[ " author " ] - > setWhatsThis ( i18n ( " <p>This link references the author.</p> " ) ) ;
tde action_map[ " author " ] = new TDEAction ( i18n ( " &Authors " ) , " mail_new " , TDEShortcut ( " Ctrl+Alt+A " ) , this , TQT_SLOT ( goAuthor ( ) ) , actionCollection ( ) , " rellinks_authors " ) ;
m_more - > insert ( tde action_map[ " author " ] ) ;
tde action_map[ " author " ] - > setWhatsThis ( i18n ( " <p>This link references the author.</p> " ) ) ;
k action_map[ " copyright " ] = new TDEAction ( i18n ( " Copy&right " ) , " signature " , TDEShortcut ( " Ctrl+Alt+R " ) , this , TQT_SLOT ( goCopyright ( ) ) , actionCollection ( ) , " rellinks_copyright " ) ;
m_more - > insert ( k action_map[ " copyright " ] ) ;
k action_map[ " copyright " ] - > setWhatsThis ( i18n ( " <p>This link references the copyright.</p> " ) ) ;
tde action_map[ " copyright " ] = new TDEAction ( i18n ( " Copy&right " ) , " signature " , TDEShortcut ( " Ctrl+Alt+R " ) , this , TQT_SLOT ( goCopyright ( ) ) , actionCollection ( ) , " rellinks_copyright " ) ;
m_more - > insert ( tde action_map[ " copyright " ] ) ;
tde action_map[ " copyright " ] - > setWhatsThis ( i18n ( " <p>This link references the copyright.</p> " ) ) ;
k actionmenu_map[ " bookmark " ] = new TDEActionMenu ( i18n ( " Bookmarks " ) , " bookmark_folder " , actionCollection ( ) , " rellinks_bookmarks " ) ;
m_more - > insert ( k actionmenu_map[ " bookmark " ] ) ;
k actionmenu_map[ " bookmark " ] - > setWhatsThis ( i18n ( " <p>This menu references the bookmarks.</p> " ) ) ;
connect ( k actionmenu_map[ " bookmark " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goBookmark ( int ) ) ) ;
k actionmenu_map[ " bookmark " ] - > setDelayed ( false ) ;
tde actionmenu_map[ " bookmark " ] = new TDEActionMenu ( i18n ( " Bookmarks " ) , " bookmark_folder " , actionCollection ( ) , " rellinks_bookmarks " ) ;
m_more - > insert ( tde actionmenu_map[ " bookmark " ] ) ;
tde actionmenu_map[ " bookmark " ] - > setWhatsThis ( i18n ( " <p>This menu references the bookmarks.</p> " ) ) ;
connect ( tde actionmenu_map[ " bookmark " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goBookmark ( int ) ) ) ;
tde actionmenu_map[ " bookmark " ] - > setDelayed ( false ) ;
k actionmenu_map[ " alternate " ] = new TDEActionMenu ( i18n ( " Other Versions " ) , " attach " , actionCollection ( ) , " rellinks_other_versions " ) ;
m_more - > insert ( k actionmenu_map[ " alternate " ] ) ;
k actionmenu_map[ " alternate " ] - > setWhatsThis ( i18n ( " <p>This link references the alternate versions of this document.</p> " ) ) ;
connect ( k actionmenu_map[ " alternate " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goAlternate ( int ) ) ) ;
k actionmenu_map[ " alternate " ] - > setDelayed ( false ) ;
tde actionmenu_map[ " alternate " ] = new TDEActionMenu ( i18n ( " Other Versions " ) , " attach " , actionCollection ( ) , " rellinks_other_versions " ) ;
m_more - > insert ( tde actionmenu_map[ " alternate " ] ) ;
tde actionmenu_map[ " alternate " ] - > setWhatsThis ( i18n ( " <p>This link references the alternate versions of this document.</p> " ) ) ;
connect ( tde actionmenu_map[ " alternate " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goAlternate ( int ) ) ) ;
tde actionmenu_map[ " alternate " ] - > setDelayed ( false ) ;
// Unclassified menu
m_links = new TDEActionMenu ( i18n ( " Miscellaneous " ) , " rellinks " , actionCollection ( ) , " rellinks_links " ) ;
k actionmenu_map[ " unclassified " ] = m_links ;
k actionmenu_map[ " unclassified " ] - > setWhatsThis ( i18n ( " <p>Miscellaneous links.</p> " ) ) ;
connect ( k actionmenu_map[ " unclassified " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goAllElements ( int ) ) ) ;
k actionmenu_map[ " unclassified " ] - > setDelayed ( false ) ;
tde actionmenu_map[ " unclassified " ] = m_links ;
tde actionmenu_map[ " unclassified " ] - > setWhatsThis ( i18n ( " <p>Miscellaneous links.</p> " ) ) ;
connect ( tde actionmenu_map[ " unclassified " ] - > popupMenu ( ) , TQT_SIGNAL ( activated ( int ) ) , this , TQT_SLOT ( goAllElements ( int ) ) ) ;
tde actionmenu_map[ " unclassified " ] - > setDelayed ( false ) ;
// We unactivate all the possible actions
disableAll ( ) ;
@ -325,33 +325,33 @@ void RelLinksPlugin::updateToolbar() {
// -- Buttons or menu items activation / creation --
if ( lrel = = " bookmark " | | lrel = = " alternate " ) {
int id = k actionmenu_map[ lrel ] - > popupMenu ( ) - > insertItem ( title ) ;
int id = tde actionmenu_map[ lrel ] - > popupMenu ( ) - > insertItem ( title ) ;
m_more - > setEnabled ( true ) ;
k actionmenu_map[ lrel ] - > setEnabled ( true ) ;
tde actionmenu_map[ lrel ] - > setEnabled ( true ) ;
element_map [ lrel ] [ id ] = e ;
} else if ( lrel = = " appendix " | | lrel = = " chapter " | | lrel = = " section " | | lrel = = " subsection " ) {
int id = k actionmenu_map[ lrel ] - > popupMenu ( ) - > insertItem ( title ) ;
int id = tde actionmenu_map[ lrel ] - > popupMenu ( ) - > insertItem ( title ) ;
m_document - > setEnabled ( true ) ;
k actionmenu_map[ lrel ] - > setEnabled ( true ) ;
tde actionmenu_map[ lrel ] - > setEnabled ( true ) ;
element_map [ lrel ] [ id ] = e ;
} else {
// It is a unique action
element_map [ lrel ] [ 0 ] = e ;
if ( k action_map[ lrel ] ) {
k action_map[ lrel ] - > setEnabled ( true ) ;
if ( tde action_map[ lrel ] ) {
tde action_map[ lrel ] - > setEnabled ( true ) ;
// Tooltip
if ( hreflang . isEmpty ( ) ) {
k action_map[ lrel ] - > setToolTip ( title ) ;
tde action_map[ lrel ] - > setToolTip ( title ) ;
} else {
k action_map[ lrel ] - > setToolTip ( title + " [ " + hreflang + " ] " ) ;
tde action_map[ lrel ] - > setToolTip ( title + " [ " + hreflang + " ] " ) ;
}
} else {
// For the moment all the elements are reference in a separated menu
// TODO : reference the unknown ?
int id = k actionmenu_map[ " unclassified " ] - > popupMenu ( ) - > insertItem ( lrel + " : " + title ) ;
k actionmenu_map[ " unclassified " ] - > setEnabled ( true ) ;
int id = tde actionmenu_map[ " unclassified " ] - > popupMenu ( ) - > insertItem ( lrel + " : " + title ) ;
tde actionmenu_map[ " unclassified " ] - > setEnabled ( true ) ;
element_map [ " unclassified " ] [ id ] = e ;
}
@ -398,8 +398,8 @@ void RelLinksPlugin::guessRelations()
DOM : : Element e = m_part - > document ( ) . createElement ( " link " ) ;
e . setAttribute ( " href " , href ) ;
element_map [ " next " ] [ 0 ] = e ;
k action_map[ " next " ] - > setEnabled ( true ) ;
k action_map[ " next " ] - > setToolTip ( title ) ;
tde action_map[ " next " ] - > setEnabled ( true ) ;
tde action_map[ " next " ] - > setToolTip ( title ) ;
if ( val > 1 )
{
@ -412,8 +412,8 @@ void RelLinksPlugin::guessRelations()
e = m_part - > document ( ) . createElement ( " link " ) ;
e . setAttribute ( " href " , href ) ;
element_map [ " prev " ] [ 0 ] = e ;
k action_map[ " prev " ] - > setEnabled ( true ) ;
k action_map[ " prev " ] - > setToolTip ( title ) ;
tde action_map[ " prev " ] - > setEnabled ( true ) ;
tde action_map[ " prev " ] - > setToolTip ( title ) ;
}
}
}
@ -533,7 +533,7 @@ void RelLinksPlugin::disableAll() {
// Clear actions
TDEActionMap : : Iterator it ;
for ( it = kaction_map. begin ( ) ; it ! = k action_map. end ( ) ; + + it ) {
for ( it = tdeaction_map. begin ( ) ; it ! = tde action_map. end ( ) ; + + it ) {
// If I don't test it crash :(
if ( it . data ( ) ) {
it . data ( ) - > setEnabled ( false ) ;
@ -543,7 +543,7 @@ void RelLinksPlugin::disableAll() {
// Clear actions
TDEActionMenuMap : : Iterator itmenu ;
for ( itmenu = k actionmenu_map. begin ( ) ; itmenu ! = k actionmenu_map. end ( ) ; + + itmenu ) {
for ( itmenu = tde actionmenu_map. begin ( ) ; itmenu ! = tde actionmenu_map. end ( ) ; + + itmenu ) {
// If I don't test it crash :(
if ( itmenu . data ( ) ) {
itmenu . data ( ) - > popupMenu ( ) - > clear ( ) ;