1. Nachrichten
  2. Forum
    1. Unerledigte Themen
    2. Forenregeln
  3. Spenden
  • Anmelden
  • Registrieren
  • Suche
Alles
  • Alles
  • Artikel
  • Seiten
  • Forum
  • Erweiterte Suche
  1. camp-firefox.de
  2. FuchsFan

Beiträge von FuchsFan

  • bookmark_count.uc.js funktioniert im Nightly nicht mehr.

    • FuchsFan
    • 19. August 2026 um 22:23

    Endor

    Geändert habe ich vor allem die Icon-Erzeugung, die explizite Größe und die URL-Behandlung. Außerdem wird der / wieder tatsächlich ausgegeben. Sieht hier so aus:

    Dann teste bitte mal:

    CSS
    // basiert auf Script von BrokenHeart
    // Firefox 154+
    
    (function() {
    
    	if (!window.gBrowser)
    		return;
    
    	setTimeout(function() {
    		setFunction();
    	}, 50);
    
    
    	// ============================================================
    	// Custom icons in profile/chrome/icons folder
    	// ============================================================
    
    	let ProfilePath = PathUtils.toFileURI(
    		PathUtils.join(PathUtils.profileDir, 'chrome', 'icons')
    	);
    
    	let icon1 = "folder.png";
    	let icon2 = "Bild36.png";
    
    	let icon1URL = `${ProfilePath}/${icon1}`;
    	let icon2URL = `${ProfilePath}/${icon2}`;
    
    
    	// ============================================================
    	// Einstellungen
    	// ============================================================
    
    	let cs_font_size = 14;
    	let cs_font_weight = 600;
    	let cs_font_color = "brown";
    
    	// feste Spaltenbreite
    	let colWidthCh = 4;
    
    
    	// ============================================================
    	// CSS
    	// ============================================================
    
    	function setFunction() {
    
    		const css = `
    
    			/*===== Counter rechtsbündig =====*/
    
    			#bmContent {
    				display: flex;
    				justify-content: flex-end;
    				align-items: center;
    				margin-top: -15px;
    				margin-right: 0px;
    				font-family: Consolas, "Lucida Console", "Courier New", monospace;
    				font-size: ${cs_font_size}px;
    				font-weight: ${cs_font_weight};
    				height: 18px;
    				white-space: nowrap;
    			}
    
    			/*============*/
    			/*   Icon 1   */
    			/*============*/
    
    			.bmIcon1 {
    				display: inline-block;
    				width: 18px;
    				min-width: 18px;
    				height: 18px;
    				min-height: 18px;
    				flex: 0 0 18px;
    				background-image: url("${icon1URL}");
    				background-repeat: no-repeat;
    				background-position: center;
    				background-size: 16px 16px;
    
    				margin-left: 6px;
    				margin-right: 0;
    				margin-top: 0px;
    			}
    
    			/*============*/
    			/*   Icon 2   */
    			/*============*/
    
    			.bmIcon2 {
    				display: inline-block;
    				width: 13px;
    				min-width: 13px;
    				height: 13px;
    				min-height: 13px;
    				flex: 0 0 13px;
    				background-image: url("${icon2URL}");
    				background-repeat: no-repeat;
    				background-position: center;
    				background-size: 13px 13px;
    
    				margin-left: 6px;
    				margin-right: 0;
    				margin-top: 0px;
    			}
    
    			/*===== Zahlen =====*/
    			
    			.bmValue {
    				color: ${cs_font_color} !important;
    				flex: 0 0 auto;
    				min-width: ${colWidthCh}ch;
    				text-align: right;
    			}
    
    
    			/*===== Slash =====*/
    			
    			.bmSlash {
    				color: ${cs_font_color} !important;
    
    				margin-left: 3px !important;
    				margin-right: -7px !important;
    			}
    
    
    			/*===== Hover-Farbwechsel =====*/
    
    			menupopup[placespopup="true"]
    			> menu.bookmark-item:hover
    			> .menu-text
    			> #bmContent
    			.bmValue {
    				color: red !important;
    			}
    
    			menupopup[placespopup="true"]
    			> menu.bookmark-item:hover
    			> .menu-text
    			> #bmContent
    			.bmSlash {
    				color: #000 !important;
    			}
    
    		`;
    
    		const sss =
    			Cc['@mozilla.org/content/style-sheet-service;1']
    			.getService(Ci.nsIStyleSheetService);
    
    		const uri = Services.io.newURI(
    			'data:text/css,' + encodeURIComponent(css)
    		);
    
    		sss.loadAndRegisterSheet(
    			uri,
    			sss.AGENT_SHEET
    		);
    
    		// ========================================================
    		// Bookmarks-Menü
    		// ========================================================
    
    		let bookMenu =
    			document.getElementById('bookmarksMenu');
    
    		let persToolBar =
    			document.getElementById('PersonalToolbar');
    
    		if (bookMenu) {
    			bookMenu.addEventListener(
    				'popupshown',
    				onPopupShowing
    			);
    		}
    
    		if (persToolBar) {
    			persToolBar.addEventListener(
    				'popupshowing',
    				onPopupShowing
    			);
    		}
    	}
    
    	// ============================================================
    	// Popup
    	// ============================================================
    
    	function onPopupShowing(aEvent) {
    
    		let popup = aEvent.originalTarget;
    
    		for (let item of popup.children) {
    
    			if (
    				item.localName != 'menu' ||
    				item.id?.startsWith('history')
    			)
    				continue;
    
    			setTimeout(() => {
    
    				let itemPopup = item.menupopup;
    
    				if (!itemPopup)
    					return;
    
    				// ------------------------------------------------
    				// Popup kurz öffnen, damit die Children
    				// zuverlässig vorhanden sind
    				// ------------------------------------------------
    
    				itemPopup.hidden = true;
    				itemPopup.collapsed = true;
    
    				itemPopup.openPopup();
    				itemPopup.hidePopup();
    
    				// ------------------------------------------------
    				// Zähler
    				// ------------------------------------------------
    
    				let menuitemCount = 0;
    				let menuCount = 0;
    
    				for (let subitem of itemPopup.children) {
    
    					if (
    						subitem.classList.contains('bookmark-item') &&
    						!subitem.disabled &&
    						!subitem.hidden
    					) {
    						if (subitem.localName == 'menuitem') {
    
    							menuitemCount++;
    						}
    						else if (subitem.localName == 'menu') {
    
    							menuCount++;
    						}
    					}
    				}
    
    				itemPopup.hidden = false;
    				itemPopup.collapsed = false;
    
    				// ------------------------------------------------
    				// Container für den Counter
    				// ------------------------------------------------
    
    				let bmCounta = item.childNodes[1];
    
    				if (!bmCounta)
    					return;
    
    				bmCounta.innerHTML = "";
    
    				let bmContent =
    					document.createXULElement("box");
    
    				bmContent.id = "bmContent";
    
    				// =================================================
    				// Anzahl Ordner
    				// =================================================
    
    				let v1 =
    					document.createXULElement("label");
    
    				v1.className = "bmValue";
    				v1.textContent = menuCount;
    
    				// =================================================
    				// Icon 1 = Ordner
    				// =================================================
    
    				let icon1El =
    					document.createXULElement("box");
    
    				icon1El.className = "bmIcon1";
    
    				// =================================================
    				// Slash
    				// =================================================
    
    				let slash =
    					document.createXULElement("label");
    
    				slash.className = "bmSlash";
    				slash.textContent = "/";
    
    				// =================================================
    				// Anzahl Lesezeichen
    				// =================================================
    
    				let v2 =
    					document.createXULElement("label");
    
    				v2.className = "bmValue";
    				v2.textContent = menuitemCount;
    
    				// =================================================
    				// Icon 2 = Lesezeichen
    				// =================================================
    
    				let icon2El =
    					document.createXULElement("box");
    
    				icon2El.className = "bmIcon2";
    
    				// =================================================
    				// Reihenfolge
    				//
    				//   Zahl1  Icon1  /  Zahl2  Icon2
    				// =================================================
    
    				bmContent.appendChild(v1);
    				bmContent.appendChild(icon1El);
    
    				bmContent.appendChild(slash);
    
    				bmContent.appendChild(v2);
    				bmContent.appendChild(icon2El);
    
    				// =================================================
    				// Einfügen
    				// =================================================
    
    				bmCounta.appendChild(bmContent);
    
    			}, 100);
    		}
    	}
    
    })();
    Alles anzeigen

    Zusammen getestet mit deinem zweiten Script:

  • userChrome.js Scripte für den Fuchs (Diskussion)

    • FuchsFan
    • 18. August 2026 um 16:44
    Zitat von lenny2

    Ich habe vor langer Zeit base64-Symbole durch Icons aus Browserressourcen ersetzt.

    Ich habe sie ganz aus dem Script entfernt, dafür die Icon mit einer css-Datei erstellt.

  • userChrome.js Scripte für den Fuchs (Diskussion)

    • FuchsFan
    • 18. August 2026 um 15:52

    Endor

    In dem Script Appmenu.uc.js (https://github.com/Endor8/userChr…5/Appmenu.uc.js ) lassen sich schon ab Firefox 153 einige Funktionen nicht mehr aufrufen. Mein Script konnte ich noch mit KI neu einrichten, dieses mit den vielen Base64-Codes will nicht gelingen. Wenn gewünscht, dann stelle ich auch mein Script zur Verfügung.

    Das ist der Ansatz, der zum Erfolg führte: Appmenü ab Fox 153.txt

    Edit:

    Nun habe ich den Base64-Code entfernt, müsste dann wieder hier image: 'den Base64-Code hier einfügen ' eingefügt werden. Das Script funktioniert dann wieder, hier dann zum Test.

    Code
    // ==UserScript==
    // @name           Appmenu.uc.js
    // @namespace      Appmenu@gmail.com
    // @description    Firefox-Menübutton für Firefox 155+
    // @include        main
    // @version        2025.01.01
    // @author         bege
    // @charset        UTF-8
    // ==/UserScript==
    
    var Appmenu = {
    
        // ==============================
        // Konfiguration
        // ==============================
    
        editor: Services.prefs.getCharPref(
            'view_source.editor.path',
            ''
        ),
    
        fileManager: '',
        FMParameter: '/T',
    
        autohideEmptySubDirs: true,
        moveSubDirstoBottom: false,
    
        // 0 = TabsToolbar
        // 1 = Navigationsleiste
        // 2 = Menüleiste
        isUrlbar: 1,
    
        // 0 = kleines Symbol
        // 1 = großes Firefox-Symbol
        isButton: 1,
    
        hotkey: 'x',
        hotkeyModifier: 'alt',
    
        subdirPopupHash: Object.create(null),
        subdirMenuHash: Object.create(null),
    
        toolbar: {
            subdirs: [
                {
                    name: 'Firefox Verzeichnisse',
                    image: ' '
                },
                {
                    name: 'Firefox Profil-Dateien',
                    image: ' '
                },
                {
                    name: 'Firefox Funktionen',
                    image: ' '
                },
                {
                    name: 'about:',
                    image: ' '
                }
            ],
    
            apps: [
                {
                    name: 'userChrome.css',
                    root: 'ProfD',
                    path: '\\chrome\\userChrome.css',
                    subdir: 'Firefox Profil-Dateien',
                    image: ' '
                },
                {
                    name: 'userContent.css',
                    root: 'ProfD',
                    path: '\\chrome\\userContent.css',
                    subdir: 'Firefox Profil-Dateien',
                    image: ' '
                },
                {
                    name: 'userChrome.js',
                    root: 'ProfD',
                    path: '\\chrome\\userChrome.js',
                    subdir: 'Firefox Profil-Dateien',
                    image: ' '
                },
                {
                    name: 'prefs.js',
                    root: 'ProfD',
                    path: '\\prefs.js',
                    subdir: 'Firefox Profil-Dateien',
                    image: ' '
                },
                {
                    name: 'user.js',
                    root: 'ProfD',
                    path: '\\user.js',
                    subdir: 'Firefox Profil-Dateien',
                    image: ' '
                },
                {
                    name: 'Profil',
                    root: 'ProfD',
                    path: '\\',
                    subdir: 'Firefox Verzeichnisse',
                    image: ' '
                },
                {
                    name: 'chrome',
                    root: 'ProfD',
                    path: '\\chrome',
                    subdir: 'Firefox Verzeichnisse',
                    image: ' '
                },
                {
                    name: 'CSS',
                    root: 'ProfD',
                    path: '\\chrome\\CSS',
                    subdir: 'Firefox Verzeichnisse',
                    image: ' '
                },
                {
                    name: 'JS',
                    root: 'ProfD',
                    path: '\\chrome\\JS',
                    subdir: 'Firefox Verzeichnisse',
                    image: ' '
                },
                {
                    name: 'Addons',
                    root: 'ProfD',
                    path: '\\extensions',
                    subdir: 'Firefox Verzeichnisse',
                    image: ' '
                },
                {
                    name: 'Programm',
                    root: 'CurProcD',
                    path: '\\',
                    subdir: 'Firefox Verzeichnisse',
                    image: ' '
                },
                {
                    name: 'Startup-Cache',
                    root: 'ProfLD',
                    path: '\\startupCache',
                    subdir: 'Firefox Verzeichnisse',
                    image: ' '
                }
            ],
    
            configs: [
                {
                    name: 'Anpassen',
                    subdir: 'Firefox Funktionen',
                    image: ' '
                },
                {
                    name: 'Neustart im abgesicherten Modus',
                    subdir: 'Firefox Funktionen',
                    image: ' '
                },
                {
                    name: 'Browser-Konsole',
                    subdir: 'Firefox Funktionen',
                    image: ' '
                },
                {
                    name: 'Entwickler-Werkzeuge',
                    subdir: 'Firefox Funktionen',
                    image: ' '
                },
                {
                    name: 'Browser-Werkzeuge',
                    subdir: 'Firefox Funktionen',
                    image: ' '
                },
                {
                    name: 'Firefox synchronisieren',
                    subdir: 'Firefox Funktionen',
                    image: ' '
                },
                {
                    name: 'Zugangsdaten und Passwörter',
                    tooltiptext: 'about:logins',
                    subdir: 'Firefox Funktionen',
                    image: ' '
                },
                {
                    name: 'Task Manager',
                    tooltiptext: 'about:processes',
                    subdir: 'Firefox Funktionen',
                    image: ' '
                },
                {
                    name: 'Offline arbeiten',
                    subdir: 'Firefox Funktionen',
                    image: ' '
                },
    
                {
                    name: 'about:about',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:cache',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:certificate',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:checkerboard',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:compat',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:config',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:crashes',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:debugging',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:downloads',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:logging',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:logins',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:memory',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:networking',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:processes',
                    tooltiptext: 'Task Manager',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:policies',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:profiles',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:profiling',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:protections',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:rights',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:serviceworkers',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:studies',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:support',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:sync-log',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:telemetry',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:third-party',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:unloads',
                    tooltiptext: 'Tabs entladen',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:url-classifier',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:webrtc',
                    subdir: 'about:',
                    image: ' '
                },
                {
                    name: 'about:windows-messages',
                    subdir: 'about:',
                    image: ' '
                },
    
                {
                    name: 'Neues privates Fenster',
                    id: 'AMprivate',
                    image: ' '
                },
                {
                    name: 'separator'
                },
                {
                    name: 'Einstellungen',
                    id: 'AMsettings',
                    image: ' '
                },
                {
                    name: 'Add-ons',
                    id: 'AMaddons',
                    image: ' '
                },
                {
                    name: 'separator'
                },
                {
                    name: 'Lesezeichen-Verwaltung',
                    id: 'AMbookmarks',
                    image: ' '
                },
                {
                    name: 'Chronik',
                    id: 'AMhistory',
                    image: ' '
                },
                {
                    name: 'Downloads',
                    id: 'AMdownloads',
                    image: ' '
                },
                {
                    name: 'Seite speichern unter...',
                    id: 'AMsave',
                    image: ' '
                },
                {
                    name: 'Chronik löschen',
                    id: 'AMsanitize',
                    image: ' '
                },
                {
                    name: 'separator'
                },
                {
                    name: 'Neustart',
                    id: 'AMreboot',
                    tooltiptext: 'userChrome.js-Cache wird geleert',
                    image: ' '
                },
                {
                    name: 'Beenden',
                    id: 'AMquit',
                    image: ' '
                }
            ]
        },
    
        _externalAppPopup: null,
        _isready: false,
    
    
        // ==============================
        // Initialisierung
        // ==============================
    
        init: function() {
            this.handleRelativePath(this.toolbar.apps);
    
            const XULNS =
                'http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul';
    
            const ExternalAppBtn = document.createElementNS(
                XULNS,
                'toolbarbutton'
            );
    
            ExternalAppBtn.id = 'AppMenuButton';
            ExternalAppBtn.setAttribute('label', 'AppButton');
            ExternalAppBtn.setAttribute('tooltiptext', 'Firefox Menü');
            ExternalAppBtn.setAttribute('type', 'menu');
            ExternalAppBtn.setAttribute('removable', 'true');
    
            // Firefox-internes Symbol statt Base64
            //ExternalAppBtn.style.listStyleImage =
            //    'url("chrome://browser/skin/menu.svg")';
    		
    		if (Appmenu.isButton) {
            ExternalAppBtn.style.listStyleImage = "url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEYAAAAUCAYAAAAwaEt4AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAF3SURBVFhH7ZUxS8RAEIX9M1fb29vb+wP8AdaCYCVY2FmInY1YWmlrp7WtNp6ihyKKCDYrb7kPxsuMJiG5CO6DR5LZmd2Zl9ndhduNUSqssggTsAgTsAgTsAgTsLEw71enyYPGHvZW8vvHzUUlrinvd5e/reX59Mk/K8zn5DrPBTyfPtlamOeTTXe8K4LHg1V3vG92KgwdI2ADT8fr+UmcfNVZ4OVspzIH0Joau9teSq/n+1Nryl1l8yA3/LUdgWLxq8NOthKJ/CQMUCE2YQuJEwkz3lqsbC+AOCoeaB5y1U8hn7qcmzB0hArkr79dHuVvhFLhs3GaU9+Tw7WpJWV/2SQIIA4bIpJbU85tK1Gg6IkLojgKtoV664kWbc+oQYRRpwh0DHZLQJztGM6LOh3T9oYcRBjrZ2F9ADYJGIFcZg9bxPFy/Y2DCCOqxe2tpHd7cwAbp3G6TVDh9mBlPp1h+va6rC4bC/NfWIQJWIQJWIQJWIRxOUpfQ+jqXwPuQ7IAAAAASUVORK5CYII=)";
        } else {
            ExternalAppBtn.style.listStyleImage = "url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAA6SURBVDhPYxgcIDg+6z8IQ7lwPiEMVT4YDBh4gO4kZGfiw1Dlg8GAgQfoTkJ2Jj4MVT4YDCAfMDAAAFSm42US1bMnAAAAAElFTkSuQmCC)";
        }
    
    
            let toolbar;
    
            if (this.isUrlbar === 1) {
                toolbar = document.getElementById(
                    'nav-bar-customization-target'
                );
            } else if (this.isUrlbar === 2) {
                toolbar = document.getElementById(
                    'toolbar-menubar'
                );
            } else {
                toolbar = document.getElementById(
                    'TabsToolbar'
                );
            }
    
            if (toolbar) {
                toolbar.insertBefore(
                    ExternalAppBtn,
                    toolbar.firstChild
                );
            }
    
            ExternalAppBtn.addEventListener('click', event => {
                event.preventDefault();
                event.stopPropagation();
            });
    
            const ExternalAppPopup = document.createElementNS(
                XULNS,
                'menupopup'
            );
    
            ExternalAppPopup.id = 'AMpopup';
    
            ExternalAppPopup.addEventListener('click', event => {
                event.stopPropagation();
            });
    
            this._externalAppPopup = ExternalAppPopup;
            ExternalAppBtn.appendChild(ExternalAppPopup);
    
            this.onpopupshowing();
    
            if (this.hotkey) {
                const key = document.createXULElement('key');
    
                key.id = 'key_AppMenuPopup';
                key.setAttribute('key', this.hotkey);
    
                if (this.hotkeyModifier) {
                    key.setAttribute(
                        'modifiers',
                        this.hotkeyModifier
                    );
                }
    
                key.addEventListener('command', () => {
                    document
                        .getElementById('AMpopup')
                        .openPopup();
                });
    
                document
                    .getElementById('mainKeyset')
                    .appendChild(key);
            }
        },
    
    
        // ==============================
        // Menü aufbauen
        // ==============================
    
        onpopupshowing: function() {
            if (this._isready || !this._externalAppPopup) {
                return;
            }
    
            const popup = this._externalAppPopup;
    
            for (const subdir of this.toolbar.subdirs) {
                if (subdir.name === 'separator') {
                    popup.appendChild(
                        document.createXULElement('menuseparator')
                    );
                    continue;
                }
    
                const menu = document.createXULElement('menu');
                const subpopup = document.createXULElement(
                    'menupopup'
                );
    
                menu.setAttribute('class', 'menu-iconic');
                menu.setAttribute('label', subdir.name);
                menu.setAttribute('image', subdir.image);
    
                menu.appendChild(subpopup);
                popup.appendChild(menu);
    
                this.subdirPopupHash[subdir.name] = subpopup;
                this.subdirMenuHash[subdir.name] = menu;
            }
    
            for (const app of this.toolbar.apps) {
                let item;
    
                if (app.name === 'separator') {
                    item = document.createXULElement(
                        'menuseparator'
                    );
                } else {
                    item = document.createXULElement('menuitem');
    
                    item.setAttribute(
                        'class',
                        'menuitem-iconic'
                    );
                    item.setAttribute('label', app.name);
                    item.setAttribute('image', app.image);
                    item.setAttribute(
                        'tooltiptext',
                        app.name
                    );
    
                    item.path = app.path;
                    item.args = app.args;
    
                    item.addEventListener('command', function() {
                        Appmenu.exec(
                            this.path,
                            this.args
                        );
                    });
                }
    
                if (
                    app.subdir &&
                    this.subdirPopupHash[app.subdir]
                ) {
                    this.subdirPopupHash[app.subdir]
                        .appendChild(item);
                } else {
                    popup.appendChild(item);
                }
            }
    
            for (const config of this.toolbar.configs) {
                let item;
    
                if (config.name === 'separator') {
                    item = document.createXULElement(
                        'menuseparator'
                    );
                } else {
                    item = document.createXULElement(
                        'menuitem'
                    );
    
                    item.setAttribute(
                        'class',
                        'menuitem-iconic'
                    );
                    item.setAttribute(
                        'label',
                        config.name
                    );
                    item.setAttribute(
                        'image',
                        config.image
                    );
                    item.setAttribute(
                        'tooltiptext',
                        config.tooltiptext ||
                        config.name
                    );
    
                    if (config.id) {
                        item.setAttribute(
                            'id',
                            config.id
                        );
                    }
    
                    item.addEventListener(
                        'command',
                        event => {
                            Appmenu.executeCommand(
                                config.name,
                                event
                            );
                        }
                    );
                }
    
                if (
                    config.subdir &&
                    this.subdirPopupHash[config.subdir]
                ) {
                    this.subdirPopupHash[config.subdir]
                        .appendChild(item);
                } else {
                    popup.appendChild(item);
                }
            }
    
            if (this.autohideEmptySubDirs) {
                for (const name in this.subdirPopupHash) {
                    const subpopup =
                        this.subdirPopupHash[name];
                    const menu =
                        this.subdirMenuHash[name];
    
                    if (
                        !subpopup.hasChildNodes() &&
                        menu
                    ) {
                        menu.setAttribute(
                            'hidden',
                            'true'
                        );
                    }
                }
            }
    
            if (this.moveSubDirstoBottom) {
                let count = popup.childNodes.length;
    
                while (
                    popup.firstChild &&
                    popup.firstChild.getAttribute(
                        'class'
                    ) !== 'menuitem-iconic' &&
                    count-- > 0
                ) {
                    popup.appendChild(
                        popup.firstChild
                    );
                }
            }
    
            this._isready = true;
        },
    
    
        // ==============================
        // Neue Befehlsausführung
        // ==============================
    
        executeCommand: function(name, event) {
            if (name.startsWith('about:')) {
                openTrustedLinkIn(
                    name,
                    gBrowser.selectedTab.isEmpty
                        ? 'current'
                        : 'tab'
                );
                return;
            }
    
            switch (name) {
                case 'Anpassen':
                    gCustomizeMode.enter();
                    break;
    
                case 'Neustart im abgesicherten Modus':
                    safeModeRestart();
                    break;
    
                case 'Browser-Konsole': {
                    const { require } =
                        ChromeUtils.importESModule(
                            'resource://devtools/shared/loader/Loader.sys.mjs',
                            {}
                        );
    
                    const { BrowserConsoleManager } =
                        require(
                            'resource://devtools/client/webconsole/browser-console-manager'
                        );
    
                    BrowserConsoleManager
                        .openBrowserConsoleOrFocus();
                    break;
                }
    
                case 'Entwickler-Werkzeuge': {
                    const { require } =
                        ChromeUtils.importESModule(
                            'resource://devtools/shared/loader/Loader.sys.mjs',
                            {}
                        );
    
                    const { gDevToolsBrowser } =
                        require(
                            'devtools/client/framework/devtools-browser'
                        );
    
                    gDevToolsBrowser
                        .toggleToolboxCommand(
                            window.gBrowser,
                            Cu.now()
                        );
                    break;
                }
    
                case 'Browser-Werkzeuge': {
                    const { require } =
                        ChromeUtils.importESModule(
                            'resource://devtools/shared/loader/Loader.sys.mjs',
                            {}
                        );
    
                    const { BrowserToolboxLauncher } =
                        require(
                            'resource://devtools/client/framework/browser-toolbox/Launcher.sys.mjs'
                        );
    
                    BrowserToolboxLauncher.init();
                    break;
                }
    
                case 'Firefox synchronisieren':
                    gSync.openPrefs('menubar');
                    break;
    
                case 'Zugangsdaten und Passwörter':
                    LoginHelper.openPasswordManager(
                        window,
                        {
                            entryPoint: 'mainmenu'
                        }
                    );
                    break;
    
                case 'Task Manager':
                    switchToTabHavingURI(
                        'about:processes',
                        true
                    );
                    break;
    
                case 'Offline arbeiten':
                    BrowserOffline.toggleOfflineStatus();
                    break;
    
                case 'Neues privates Fenster':
                    OpenBrowserWindow({
                        private: true
                    });
                    break;
    
                case 'Einstellungen':
                    openPreferences();
                    break;
    
                case 'Add-ons':
                    BrowserAddonUI.openAddonsMgr();
                    break;
    
                case 'Lesezeichen-Verwaltung':
                    PlacesCommandHook
                        .showPlacesOrganizer(
                            'AllBookmarks'
                        );
                    break;
    
                case 'Chronik':
                    PlacesCommandHook
                        .showPlacesOrganizer(
                            'History'
                        );
                    break;
    
                case 'Downloads':
                    BrowserCommands.downloadsUI();
                    break;
    
                case 'Seite speichern unter...':
                    saveBrowser(
                        gBrowser.selectedBrowser
                    );
                    break;
    
                case 'Chronik löschen':
                    Sanitizer.showUI(window);
                    break;
    
                case 'Neustart':
                    Services.appinfo
                        .invalidateCachesOnRestart();
    
                    Services.startup.quit(
                        Ci.nsIAppStartup.eRestart |
                        Ci.nsIAppStartup.eAttemptQuit
                    );
                    break;
    
                case 'Beenden':
                    goQuitApplication(event);
                    break;
    
                default:
                    console.error(
                        'Appmenu: Unbekannter Befehl: ' +
                        name
                    );
            }
        },
    
    
        // ==============================
        // Pfade verarbeiten
        // ==============================
    
        handleRelativePath: function(apps) {
            for (const app of apps) {
                if (!app.path) {
                    continue;
                }
    
                app.path = app.path.replace(
                    /\//g,
                    '\\'
                );
    
                const ffdir = Cc[
                    '@mozilla.org/file/directory_service;1'
                ]
                    .getService(Ci.nsIProperties)
                    .get(app.root, Ci.nsIFile)
                    .path;
    
                if (/^\\/.test(app.path)) {
                    app.path = ffdir + app.path;
                }
            }
        },
    
    
        // ==============================
        // Dateien und Ordner öffnen
        // ==============================
    
        exec: function(path, args) {
            args = args || [];
    
            const args_t = args.slice(0);
    
            for (let i = 0; i < args_t.length; i++) {
                args_t[i] = args_t[i].replace(
                    /%u/g,
                    gBrowser.currentURI.spec
                );
            }
    
            const file = Cc[
                '@mozilla.org/file/local;1'
            ].createInstance(Ci.nsIFile);
    
            file.initWithPath(path);
    
            if (!file.exists()) {
                alert(
                    'Datei nicht gefunden: ' +
                    path
                );
                return;
            }
    
            if (
                file.isExecutable() &&
                !path.endsWith('.js')
            ) {
                const process = Cc[
                    '@mozilla.org/process/util;1'
                ].createInstance(Ci.nsIProcess);
    
                process.init(file);
                process.run(
                    false,
                    args_t,
                    args_t.length
                );
                return;
            }
    
            if (file.isFile()) {
                if (this.editor) {
                    const converter = Cc[
                        '@mozilla.org/intl/scriptableunicodeconverter'
                    ].createInstance(
                        Ci.nsIScriptableUnicodeConverter
                    );
    
                    converter.charset =
                        window.navigator.platform
                            .toLowerCase()
                            .includes('win')
                            ? 'Shift_JIS'
                            : 'UTF-8';
    
                    const convertedPath =
                        converter.ConvertFromUnicode(
                            file.path
                        );
    
                    const editor =
                        Cc[
                            '@mozilla.org/file/local;1'
                        ].createInstance(Ci.nsIFile);
    
                    editor.initWithPath(
                        this.editor
                    );
    
                    const process = Cc[
                        '@mozilla.org/process/util;1'
                    ].createInstance(Ci.nsIProcess);
    
                    process.init(editor);
                    process.run(
                        false,
                        [convertedPath],
                        1
                    );
                } else {
                    file.launch();
                }
    
                return;
            }
    
            if (file.isDirectory()) {
                if (this.fileManager) {
                    const fmArgs = [
                        this.FMParameter,
                        path
                    ];
    
                    const manager = Cc[
                        '@mozilla.org/file/local;1'
                    ].createInstance(Ci.nsIFile);
    
                    manager.initWithPath(
                        this.fileManager
                    );
    
                    const process = Cc[
                        '@mozilla.org/process/util;1'
                    ].createInstance(Ci.nsIProcess);
    
                    process.init(manager);
                    process.run(
                        false,
                        fmArgs,
                        fmArgs.length
                    );
                } else {
                    file.launch();
                }
            }
        }
    };
    
    
    if (window.gBrowser) {
        Appmenu.init();
    }
    Alles anzeigen
  • 1 Script funktioniert nicht mehr und ich weiss nicht, welches es von diesen 2 (Zusatzleisten) ist.

    • FuchsFan
    • 15. August 2026 um 14:04
    Zitat von 2002Andreas

    Jetzt ist ja zwecks Test ein Fx Icon drin, das müsste dann auf jeden Fall bei ihm angezeigt werden.

    Ja, hatte ich schon gesehen.:thumbup:

  • 1 Script funktioniert nicht mehr und ich weiss nicht, welches es von diesen 2 (Zusatzleisten) ist.

    • FuchsFan
    • 15. August 2026 um 14:00
    Zitat von 2002Andreas

    ob es funktioniert bzw. das Icon und der Tooltip angezeigt werden

    Ja, natürlich. Um sicher zu gehen, so habe ich gestern unterschiedliche Pfade und Ordner genutzt, Icon wurde immer angezeigt.

  • 1 Script funktioniert nicht mehr und ich weiss nicht, welches es von diesen 2 (Zusatzleisten) ist.

    • FuchsFan
    • 15. August 2026 um 13:57
    Zitat von 2002Andreas

    Wenn die nicht mehr stimmen bei ihm, dann dürfte doch aber gar kein Skript mehr funktionieren :/

    Ja, Andreas, da habe ich auch dran gedacht, aber um absolut sicher zu gehen dieser Versuch.

  • 1 Script funktioniert nicht mehr und ich weiss nicht, welches es von diesen 2 (Zusatzleisten) ist.

    • FuchsFan
    • 15. August 2026 um 13:48

    omar1979

    Bevor du jetzt weiter machst mit den Profilen, erledige diesen Schritt. Und zwar, rufe den Installationsordner von Firefox auf, und lösche die beiden Dateien daraus:

    Dann füge die aus dem ZIP-Archiv dort wieder ein. Neustart (ganz beenden, und wieder neu starten).

    Ordner.zip

  • 1 Script funktioniert nicht mehr und ich weiss nicht, welches es von diesen 2 (Zusatzleisten) ist.

    • FuchsFan
    • 15. August 2026 um 10:10
    Zitat von 2002Andreas

    Ein Skript extra-config ist dort vorhanden, sonst gäbe es ja keinen Tooltip wie auf dem Screenshot zu sehen ist.

    Richtig!;)

    Er schreibt auch immer nur "funktioniert nicht", meint er jetzt nur das fehlende Icon, oder generell das Script. :/

  • 1 Script funktioniert nicht mehr und ich weiss nicht, welches es von diesen 2 (Zusatzleisten) ist.

    • FuchsFan
    • 15. August 2026 um 09:00
    Zitat von omar1979

    im about:profiles habe ich 2 Profile.

    Das ist das Profil, das du verwendest:

    In dem ersten Script was du uns gezeigt hast (das ich auch angepasst habe) ist für das Icon das Profil c612nnc8.default-release angegeben, deswegen kann es nicht funktionieren. Öffne den Wurzelordner (siehe Bild) und schau nach, ob alle Scripte, die du im Einsatz hast, dort auch vorhanden sind. In dem extra-config-script musst du dann in Zeile 151 (nach /Profiles/xxxx) den richtigen Profilnamen eintragen (siehe Bild).

  • 1 Script funktioniert nicht mehr und ich weiss nicht, welches es von diesen 2 (Zusatzleisten) ist.

    • FuchsFan
    • 14. August 2026 um 22:08
    Zitat von omar1979

    muss ich hier was ändern, damit es funktioniert?

    Nein, denn das Script funktioniert von Version 153 bis 155. Jetzt noch einmal das Script mit dem richtigen Iconpfad. Sollte das Script nicht funktionieren bei dir, ja dann verstehe ich nur nicht was in deinem Profil passiert. Teste erst einmal:

    CSS
    // ==UserScript==
    // @name           extras_config_menu.uc.js
    // @compatibility  Firefox 5*.*
    // @include        main
    // @version        2.0.20260814
    // @description    Extra-Konfigurationsmenü ohne Inline-JavaScript und ohne eval
    // ==/UserScript==
    
    var uProfMenu = {
      /*
       * =========================
       * Beginn der Konfiguration
       * =========================
       */
    
      // Texteditor
      TextOpenExe: 'D:\\PortableProgramme\\Notepad++Portable_x64\\notepad++.exe',
      
      // Dateimanager:
      // Leer lassen, damit der Dateimanager des Systems verwendet wird.
      vFileManager: '',
    
      // Unterordner für userChromeJS-Scripte.
      // Leer lassen, wenn die Scripte direkt im Chrome-Ordner liegen.
      jsSubfolder: 'Scripte',
    
      /*
       * 'menu'  = Eintrag unter Extras
       * sonst   = ID des Elements, nach dem der Button eingefügt werden soll
       */
      warpmenuto: 'urlbar-container',
    
      // 1 = Sortierung erzwingen, 0 = keine Sortierung
      sortScripts: 0,
    
      /*
       * GM-Scripte:
       * 0 = nein
       * 1 = Greasemonkey
       * 2 = UserScriptLoader
       * 3 = Scriptish
       */
      gmOrdner: 0,
    
      // CSS-Ordner einbinden: 0 = nein, 1 = ja
      cssOrdner: 0,
    
      /*
       * Ordnernamen exakt an die tatsächlichen Ordnernamen anpassen.
       * Unter Linux ist Groß-/Kleinschreibung relevant.
       */
      cssFolderName: 'CSS',
      cssShadowFolderName: 'CSSShadow',
      cssWebFolderName: 'CSSWeb',
    
      // Aufzurufende about:-Seiten
      abouts: [
        'about:about',
        'about:debugging#/runtime/this-firefox',
        'about:cache',
        'about:config',
        'about:crashes',
        'about:downloads',
        'about:home',
        'about:logins',
        'about:memory',
        'about:support',
        'about:preferences',
        'about:performance',
        'about:profiles'
      ],
    
      // Normale Firefox-Einstellungen anzeigen
      showNormalPrefs: 0,
    
      /*
       * Skriptliste in die Zwischenablage:
       * 0 = nein
       * 1 = ohne Nummerierung
       * 2 = getrennte Nummerierung
       * 3 = gemeinsame Nummerierung
       */
      enableScriptsToClip: 1,
    
      // Neustart-Eintrag erzwingen
      enableRestart: 0,
    
      /*
       * =======================
       * Ende der Konfiguration
       * =======================
       */
    
    
      init: function() {
        var menu;
    
        if (this.warpmenuto.toLowerCase() == 'menu') {
          var zielmenu = document.getElementById('menu_ToolsPopup');
    
          if (!zielmenu) {
            if (typeof userChrome != 'undefined' && userChrome.log) {
              userChrome.log(
                'extras_config_menu.uc.js findet das Zielmenü nicht.'
              );
            }
            return;
          }
    
          menu = zielmenu.appendChild(
            this.createMenuElement(
              'menu',
              'Config Menü',
              'ExtraConfigMenu'
            )
          );
    
          menu.setAttribute('class', 'menu-iconic');
    
          menu.addEventListener('dblclick', function() {
            openTrustedLinkIn('about:config', 'tab');
          });
    
        } else {
          if (window.__SSi == 'window0') {
            CustomizableUI.createWidget({
              id: 'ExtraConfigMenu-button',
              defaultArea: CustomizableUI.AREA_NAVBAR,
              label: 'Extra Config Menü',
              tooltiptext: 'Extra Config Menü\nMittelklick öffnet about:config'
            });
          }
    
          menu = document.getElementById('ExtraConfigMenu-button');
    
          if (!menu) {
            return;
          }
    
          menu.setAttribute('type', 'menu');
    
          menu.addEventListener('click', function(event) {
            if (event.button == 1) {
              openTrustedLinkIn('about:config', 'tab');
            }
          });
        }
    
        var css =
          '#ExtraConfigMenu, #ExtraConfigMenu-button {' +
          '  list-style-image: url(file:///C:/Users/Ramo/AppData/Roaming/Mozilla/Firefox/Profiles/c612nnc8.default-release/chrome/Icons/extraConf.png);' +
          '}' +
          '#ExtraConfigMenu-button > dropmarker,' +
          '#ExtraConfigMenu-button > hbox > .toolbarbutton-menu-dropmarker {' +
          '  display: none !important;' +
          '}';
    
        var sss = Cc[
          '@mozilla.org/content/style-sheet-service;1'
        ].getService(Ci.nsIStyleSheetService);
    
        var uri = Services.io.newURI(
          'data:text/css;charset=UTF-8,' + encodeURIComponent(css)
        );
    
        if (!sss.sheetRegistered(uri, sss.AGENT_SHEET)) {
          sss.loadAndRegisterSheet(uri, sss.AGENT_SHEET);
        }
    
        menu.addEventListener('popupshowing', function() {
          uProfMenu.getScripts(0);
          uProfMenu.getCss(3);
          uProfMenu.getCss(4);
          uProfMenu.getCss(5);
        });
    
        var menupopup = menu.appendChild(
          this.createMenuElement(
            'menupopup',
            '',
            'ExtraConfigMenu-popup'
          )
        );
    
        /*
         * UserChromeJS-Scripte
         */
        var submenu = menupopup.appendChild(
          this.createMenuElement('menu', 'Scripte', 'submenu-ucjs')
        );
    
        submenu.appendChild(
          this.createMenuElement(
            'menupopup',
            '',
            'submenu-ucjs-items'
          )
        );
    
        /*
         * CSS
         */
        submenu = menupopup.appendChild(
          this.createMenuElement('menu', 'CSS', 'submenu-css')
        );
    
        submenu.appendChild(
          this.createMenuElement(
            'menupopup',
            '',
            'submenu-css-items'
          )
        );
    
        /*
         * CSSShadow
         */
        submenu = menupopup.appendChild(
          this.createMenuElement(
            'menu',
            'CSSShadow',
            'submenu-CSSShadow'
          )
        );
    
        submenu.appendChild(
          this.createMenuElement(
            'menupopup',
            '',
            'submenu-CSSShadow-items'
          )
        );
    
        /*
         * CSSWeb
         */
        submenu = menupopup.appendChild(
          this.createMenuElement(
            'menu',
            'CSSWeb',
            'submenu-cssweb'
          )
        );
    
        submenu.appendChild(
          this.createMenuElement(
            'menupopup',
            '',
            'submenu-cssweb-items'
          )
        );
    
        /*
         * about:-Seiten
         */
        if (this.abouts.length > 0) {
          menupopup.appendChild(document.createXULElement('menuseparator'));
    
          if (this.abouts[0] == '0') {
            for (var i = 1; i < this.abouts.length; i++) {
              menupopup.appendChild(
                this.createMenuItem(
                  this.abouts[i],
                  function(event) {
                    openTrustedLinkIn(
                      event.currentTarget.getAttribute('data-url'),
                      'tab'
                    );
                  },
                  'uProfMenu_about',
                  {
                    'data-url': this.abouts[i]
                  }
                )
              );
            }
          } else {
            submenu = menupopup.appendChild(
              this.createMenuElement(
                'menu',
                'about-Seiten',
                'submenu-about'
              )
            );
    
            submenu.appendChild(
              this.createMenuElement(
                'menupopup',
                '',
                'submenu-about-items'
              )
            );
    
            this.fillMenu(
              'submenu-about',
              'submenu-about-items',
              'about-Seiten',
              this.abouts,
              'uProfMenu_about',
              1
            );
          }
        }
    
        /*
         * Zwischenablage
         */
        if (this.enableScriptsToClip) {
          menupopup.appendChild(
            this.createMenuItem(
              'Scriptliste in Zwischenablage kopieren',
              function() {
                uProfMenu.getScripts(1);
              },
              'uProfMenu_clipboard'
            )
          );
        }
    
        menupopup.appendChild(
          document.createXULElement('menuseparator')
        );
    
        /*
         * Konfigurationsdateien
         */
        menupopup.appendChild(
          this.createMenuItem(
            'userChrome.css',
            function() {
              uProfMenu.edit(6, 'userChrome.css');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'userChromeShadow.css',
            function() {
              uProfMenu.edit(6, 'userChromeShadow.css');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'userContent.css',
            function() {
              uProfMenu.edit(6, 'userContent.css');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'userChrome.js',
            function() {
              uProfMenu.edit(6, 'userChrome.js');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'prefs.js',
            function() {
              uProfMenu.edit(1, 'prefs.js');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'user.js',
            function() {
              uProfMenu.edit(1, 'user.js');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          document.createXULElement('menuseparator')
        );
    
        /*
         * Ordner
         */
        switch (this.gmOrdner) {
          case 1:
            menupopup.appendChild(
              this.createMenuItem(
                'GM-Scripte',
                function() {
                  uProfMenu.dirOpen(
                    uProfMenu.getPrefDirectoryPath('ProfD') +
                    uProfMenu.getDirSep() +
                    'gm_scripts'
                  );
                },
                'uProfMenu_folder'
              )
            );
            break;
    
          case 2:
            menupopup.appendChild(
              this.createMenuItem(
                'USL-Scripte',
                function() {
                  uProfMenu.dirOpen(
                    uProfMenu.getPrefDirectoryPath('UChrm') +
                    uProfMenu.getDirSep() +
                    'UserScriptLoader'
                  );
                },
                'uProfMenu_folder'
              )
            );
            break;
    
          case 3:
            menupopup.appendChild(
              this.createMenuItem(
                'Scriptish-Scripte',
                function() {
                  uProfMenu.dirOpen(
                    uProfMenu.getPrefDirectoryPath('ProfD') +
                    uProfMenu.getDirSep() +
                    'scriptish_scripts'
                  );
                },
                'uProfMenu_folder'
              )
            );
            break;
        }
    
        menupopup.appendChild(
          this.createMenuItem(
            'Scripte-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('UChrm') +
                uProfMenu.getDirSep() +
                uProfMenu.jsSubfolder
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'CSS-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('UChrm') +
                uProfMenu.getDirSep() +
                uProfMenu.cssFolderName
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'CSSShadow-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('UChrm') +
                uProfMenu.getDirSep() +
                uProfMenu.cssShadowFolderName
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'CSSWeb-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('UChrm') +
                uProfMenu.getDirSep() +
                uProfMenu.cssWebFolderName
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Chrome-Ordner öffnen',
            function() {
              uProfMenu.prefDirOpen('UChrm');
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Profil-Ordner öffnen',
            function() {
              uProfMenu.prefDirOpen('ProfD');
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Icons-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('UChrm') +
                uProfMenu.getDirSep() +
                'Icons'
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Installations-Ordner öffnen',
            function() {
              uProfMenu.prefDirOpen('CurProcD');
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Add-ons-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('ProfD') +
                uProfMenu.getDirSep() +
                'extensions'
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Startup-Cache-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('ProfLD') +
                uProfMenu.getDirSep() +
                'startupCache'
              );
            },
            'uProfMenu_folder'
          )
        );
    
        /*
         * Normale Einstellungen
         */
        if (
          this.abouts.length == 0 &&
          (this.showNormalPrefs ||
           typeof ToolRstartMod != 'undefined')
        ) {
          menupopup.appendChild(
            document.createXULElement('menuseparator')
          );
        }
    
        if (this.showNormalPrefs) {
          menupopup.appendChild(
            this.createMenuItem(
              'Einstellungen',
              function() {
                try {
                  openOptionsDialog();
                } catch (e) {
                  openPreferences();
                }
              },
              'uProfMenu_prefs'
            )
          );
        }
    
        /*
         * Neustart
         */
        if (
          typeof ToolRstartMod != 'undefined' ||
          this.enableRestart
        ) {
          menupopup.appendChild(
            this.createMenuItem(
              'Neustart',
              function() {
                try {
                  ToolRstartMod.restartApp(false);
                } catch (e) {
                  alert(e);
                }
              },
              'uProfMenu_restart'
            )
          );
        }
      },
    
    
      getDirSep: function() {
        var osString = Services.appinfo.OS;
    
        switch (osString) {
          case 'WINNT':
            return '\\';
    
          case 'Linux':
          case 'Darwin':
          default:
            return '/';
        }
      },
    
    
      edit: function(openMode, filename) {
        var dSep = this.getDirSep();
        var path;
    
        switch (openMode) {
          case 0:
            path = this.getPrefDirectoryPath('UChrm');
    
            if (this.jsSubfolder.length != 0) {
              path += dSep + this.jsSubfolder;
            }
    
            path += dSep + filename;
            break;
    
          case 1:
            path =
              this.getPrefDirectoryPath('ProfD') +
              dSep +
              filename;
            break;
    
          case 2:
            path = filename;
            break;
    
          case 3:
            path =
              this.getPrefDirectoryPath('UChrm') +
              dSep +
              this.cssFolderName +
              dSep +
              filename;
            break;
    
          case 4:
            path =
              this.getPrefDirectoryPath('UChrm') +
              dSep +
              this.cssWebFolderName +
              dSep +
              filename;
            break;
    
          case 5:
            path =
              this.getPrefDirectoryPath('UChrm') +
              dSep +
              this.cssShadowFolderName +
              dSep +
              filename;
            break;
    
          case 6:
            path =
              this.getPrefDirectoryPath('UChrm') +
              dSep +
              filename;
            break;
    
          default:
            return;
        }
    
        this.launch(this.TextOpenExe, path);
      },
    
    
      dirOpen: function(path) {
        if (this.vFileManager.length != 0) {
          var file = Cc[
            '@mozilla.org/file/local;1'
          ].createInstance(Ci.nsIFile);
    
          var process = Cc[
            '@mozilla.org/process/util;1'
          ].createInstance(Ci.nsIProcess);
    
          file.initWithPath(this.vFileManager);
          process.init(file);
    
          var args = [path];
          process.run(false, args, args.length);
        } else {
          var dir = Cc[
            '@mozilla.org/file/local;1'
          ].createInstance(Ci.nsIFile);
    
          dir.initWithPath(path);
          dir.launch();
        }
      },
    
    
      prefDirOpen: function(prefDir) {
        var path = this.getPrefDirectoryPath(prefDir);
        this.dirOpen(path);
      },
    
    
      getPrefDirectoryPath: function(prefDir) {
        var file = Services.dirsvc.get(prefDir, Ci.nsIFile);
    
        if (prefDir == 'CurProcD') {
          file = file.parent;
        }
    
        return file.path;
      },
    
    
      launch: function(editorPath, filePath) {
        var file = Cc[
          '@mozilla.org/file/local;1'
        ].createInstance(Ci.nsIFile);
    
        var process = Cc[
          '@mozilla.org/process/util;1'
        ].createInstance(Ci.nsIProcess);
    
        file.initWithPath(editorPath);
    
        /*
         * Falls der konfigurierte Editor nicht existiert,
         * view_source.editor.path verwenden.
         */
        if (!file.exists()) {
          try {
            editorPath = Services.prefs.getStringPref(
              'view_source.editor.path'
            );
          } catch (e) {
            alert(
              'Editor nicht gefunden und view_source.editor.path ist nicht gesetzt.'
            );
            return;
          }
    
          file.initWithPath(editorPath);
        }
    
        if (!file.exists()) {
          alert('Editor nicht gefunden:\n' + editorPath);
          return;
        }
    
        process.init(file);
    
        var args = [filePath];
        process.run(false, args, args.length);
      },
    
    
      stringComparison: function(a, b) {
        function normalize(value) {
          return value
            .toLowerCase()
            .replace(/ä/g, 'a')
            .replace(/ö/g, 'o')
            .replace(/ü/g, 'u')
            .replace(/ß/g, 's');
        }
    
        a = normalize(a);
        b = normalize(b);
    
        return a == b ? 0 : a > b ? 1 : -1;
      },
    
    
      getScripts: function(type) {
        var ucJsScripts = [];
        var folderPath = Services.dirsvc.get(
          'UChrm',
          Ci.nsIFile
        ).path;
    
        if (this.jsSubfolder.length != 0) {
          folderPath +=
            this.getDirSep() +
            this.jsSubfolder;
        }
    
        var folder = Cc[
          '@mozilla.org/file/local;1'
        ].createInstance(Ci.nsIFile);
    
        folder.initWithPath(folderPath);
    
        if (folder.exists() && folder.isDirectory()) {
          var files = folder.directoryEntries;
    
          while (files.hasMoreElements()) {
            var file = files
              .getNext()
              .QueryInterface(Ci.nsIFile);
    
            if (/\.uc\.js$/i.test(file.leafName)) {
              ucJsScripts.push(file.leafName);
            }
          }
        }
    
        if (this.sortScripts) {
          ucJsScripts.sort(this.stringComparison);
        }
    
        if (type == 0) {
          this.fillMenu(
            'submenu-ucjs',
            'submenu-ucjs-items',
            'Meine Scripte',
            ucJsScripts,
            'uProfMenu_ucjs',
            0
          );
        } else {
          var result = this.fillClipboardValue(
            ucJsScripts,
            []
          );
    
          Cc[
            '@mozilla.org/widget/clipboardhelper;1'
          ].getService(Ci.nsIClipboardHelper).copyString(result);
        }
      },
    
    
      getCss: function(type) {
        var cssFiles = [];
        var folderName;
    
        switch (type) {
          case 3:
            folderName = this.cssFolderName;
            break;
    
          case 4:
            folderName = this.cssWebFolderName;
            break;
    
          case 5:
            folderName = this.cssShadowFolderName;
            break;
    
          default:
            return;
        }
    
        var folderPath =
          Services.dirsvc.get('UChrm', Ci.nsIFile).path +
          this.getDirSep() +
          folderName;
    
        var folder = Cc[
          '@mozilla.org/file/local;1'
        ].createInstance(Ci.nsIFile);
    
        folder.initWithPath(folderPath);
    
        if (folder.exists() && folder.isDirectory()) {
          var files = folder.directoryEntries;
    
          while (files.hasMoreElements()) {
            var file = files
              .getNext()
              .QueryInterface(Ci.nsIFile);
    
            if (/\.css$/i.test(file.leafName)) {
              cssFiles.push(file.leafName);
            }
          }
        }
    
        if (this.sortScripts) {
          cssFiles.sort(this.stringComparison);
        }
    
        if (type == 3) {
          this.fillMenu(
            'submenu-css',
            'submenu-css-items',
            'Meine CSS-Dateien',
            cssFiles,
            'uProfMenu_css',
            3
          );
        } else if (type == 4) {
          this.fillMenu(
            'submenu-cssweb',
            'submenu-cssweb-items',
            'Meine CSSWeb-Dateien',
            cssFiles,
            'uProfMenu_css',
            4
          );
        } else if (type == 5) {
          this.fillMenu(
            'submenu-CSSShadow',
            'submenu-CSSShadow-items',
            'Meine CSSShadow-Dateien',
            cssFiles,
            'uProfMenu_css',
            5
          );
        }
      },
    
    
      fillMenu: function(
        submenuId,
        submenuItemsId,
        label,
        fileArray,
        itemClass,
        type
      ) {
        var submenu = document.getElementById(submenuId);
        var popup = document.getElementById(submenuItemsId);
    
        if (!submenu || !popup) {
          return;
        }
    
        submenu.setAttribute(
          'label',
          label + ' (' + fileArray.length + ')'
        );
    
        while (popup.firstChild) {
          popup.removeChild(popup.firstChild);
        }
    
        for (var i = fileArray.length - 1; i >= 0; i--) {
          var filename = fileArray[i];
          var menuitem;
    
          if (type == 0) {
            menuitem = this.createMenuItem(
              filename,
              function(event) {
                var name =
                  event.currentTarget.getAttribute('data-filename');
    
                if (event.button == 1) {
                  uProfMenu.openAtGithub(event, name);
                } else if (event.button == 2) {
                  uProfMenu.openAtGithub(event, name);
                }
              },
              itemClass,
              {
                'data-filename': filename
              }
            );
    
            menuitem.setAttribute(
              'tooltiptext',
              'Linksklick: Bearbeiten\n' +
              'Mittelklick: GitHub öffnen\n' +
              'Rechtsklick: Suche auf GitHub'
            );
    
            menuitem.addEventListener('command', function(event) {
              uProfMenu.edit(
                0,
                event.currentTarget.getAttribute('data-filename')
              );
            });
    
          } else if (type == 1) {
            menuitem = this.createMenuItem(
              filename,
              function(event) {
                openTrustedLinkIn(
                  event.currentTarget.getAttribute('data-url'),
                  'tab'
                );
              },
              itemClass,
              {
                'data-url': filename
              }
            );
    
          } else if (type == 3) {
            menuitem = this.createMenuItem(
              filename,
              function(event) {
                uProfMenu.edit(
                  3,
                  event.currentTarget.getAttribute('data-filename')
                );
              },
              itemClass,
              {
                'data-filename': filename
              }
            );
    
          } else if (type == 4) {
            menuitem = this.createMenuItem(
              filename,
              function(event) {
                uProfMenu.edit(
                  4,
                  event.currentTarget.getAttribute('data-filename')
                );
              },
              itemClass,
              {
                'data-filename': filename
              }
            );
    
          } else if (type == 5) {
            menuitem = this.createMenuItem(
              filename,
              function(event) {
                uProfMenu.edit(
                  5,
                  event.currentTarget.getAttribute('data-filename')
                );
              },
              itemClass,
              {
                'data-filename': filename
              }
            );
          }
    
          if (menuitem) {
            popup.insertBefore(menuitem, popup.firstChild);
          }
        }
      },
    
    
      fillClipboardValue: function(scriptArray, xulArray) {
        var scriptCount = scriptArray.length;
        var xulCount = xulArray.length;
        var result;
    
        switch (this.enableScriptsToClip) {
          case 1:
            result =
              'userChromeJS/uc.js (' +
              scriptCount +
              '):\n' +
              '------------------------\n' +
              scriptArray.join('\n') +
              '\n\n' +
              'userChromeJS/uc.xul (' +
              xulCount +
              '):\n' +
              '-------------------------\n' +
              xulArray.join('\n');
            break;
    
          case 2:
          case 3:
            result =
              'userChromeJS/uc.js (' +
              scriptCount +
              '):\n' +
              '------------------------';
    
            for (var i = 0; i < scriptCount; i++) {
              result += '\n' + (i + 1) + '. ' + scriptArray[i];
            }
    
            result +=
              '\n\nuserChromeJS/uc.xul (' +
              xulCount +
              '):\n' +
              '-------------------------';
    
            for (var j = 0; j < xulCount; j++) {
              var number = j + 1;
    
              if (this.enableScriptsToClip == 3) {
                number += scriptCount;
              }
    
              result += '\n' + number + '. ' + xulArray[j];
            }
            break;
    
          default:
            result = '';
        }
    
        return result;
      },
    
    
      createMenuElement: function(type, label, id) {
        var element = document.createXULElement(type);
    
        if (label) {
          element.setAttribute('label', label);
        }
    
        if (id) {
          element.setAttribute('id', id);
        }
    
        return element;
      },
    
    
      createMenuItem: function(label, callback, className, attributes) {
        var item = document.createXULElement('menuitem');
    
        item.setAttribute('label', label);
    
        if (className) {
          item.setAttribute('class', className);
        }
    
        if (attributes) {
          for (var name in attributes) {
            item.setAttribute(name, attributes[name]);
          }
        }
    
        /*
         * Kein oncommand-Attribut und kein Inline-JavaScript:
         * Die Funktion wird direkt als Event-Listener registriert.
         */
        item.addEventListener('command', callback);
    
        /*
         * Für Mittelklick und Rechtsklick wird zusätzlich das click-Event
         * verwendet. Der normale Linksklick läuft über command.
         */
        item.addEventListener('click', callback);
    
        return item;
      },
    
    
      openAtGithub: function(event, scriptName) {
        if (event.button == 1) {
          var githubUrl =
            'https://github.com/ardiman/userChrome.js/tree/master/' +
            this.cleanFileName(scriptName);
    
          openWebLinkIn(githubUrl, 'tab');
    
        } else if (event.button == 2) {
          event.preventDefault();
    
          var searchUrl =
            'https://github.com/search?langOverride=&language=&q=' +
            encodeURIComponent(scriptName) +
            '&repo=&start_value=1&type=Code';
    
          openWebLinkIn(searchUrl, 'tab');
        }
      },
    
    
      cleanFileName: function(name) {
        name = name.toLowerCase();
    
        var expressions = [
          /\.uc\.js$/,
          /\.uc\.xul$/,
          /^ucjs_/,
          /_\d.+/,
          /_fx\d+/,
          /[-+\.]/g,
          /_v\d+/
        ];
    
        for (var i = 0; i < expressions.length; i++) {
          name = name.replace(expressions[i], '');
        }
    
        return name;
      }
    };
    
    
    /*
     * Script starten
     */
    uProfMenu.init();
    Alles anzeigen
  • 1 Script funktioniert nicht mehr und ich weiss nicht, welches es von diesen 2 (Zusatzleisten) ist.

    • FuchsFan
    • 14. August 2026 um 20:13
    Zitat von omar1979

    ich benütze dieses Script, funktioniert aber nicht, zeigt kein icon an, nur das Feld dafür ist leer und auf klick passiert aucht nichts.

    Deswegen teste erst einmal das Script aus dem Beitrag darüber, ob es bei dir funktioniert. Über das Icon reden wir dann danach.

  • 1 Script funktioniert nicht mehr und ich weiss nicht, welches es von diesen 2 (Zusatzleisten) ist.

    • FuchsFan
    • 14. August 2026 um 20:04

    omar1979

    Ich habe jetzt mal dein Script von hier erneuert, es funktioniert hier in Version 155, probiere es aus. Wenn du dann doch ein anderes nutzt, dann stelle es hier rein, werde dir dabei helfen wenn du möchtest. Hier erst einmal das Script (funktioniert ohne eval-Schalter).

    CSS
    // ==UserScript==
    // @name           extras_config_menu.uc.js
    // @compatibility  Firefox 5*.*
    // @include        main
    // @version        2.0.20260814
    // @description    Extra-Konfigurationsmenü ohne Inline-JavaScript und ohne eval
    // ==/UserScript==
    
    var uProfMenu = {
      /*
       * =========================
       * Beginn der Konfiguration
       * =========================
       */
    
      // Texteditor
      TextOpenExe: 'D:\\PortableProgramme\\Notepad++Portable_x64\\notepad++.exe',
    
      // Dateimanager:
      // Leer lassen, damit der Dateimanager des Systems verwendet wird.
      vFileManager: '',
    
      // Unterordner für userChromeJS-Scripte.
      // Leer lassen, wenn die Scripte direkt im Chrome-Ordner liegen.
      jsSubfolder: 'Scripte',
    
      /*
       * 'menu'  = Eintrag unter Extras
       * sonst   = ID des Elements, nach dem der Button eingefügt werden soll
       */
      warpmenuto: 'urlbar-container',
    
      // 1 = Sortierung erzwingen, 0 = keine Sortierung
      sortScripts: 0,
    
      /*
       * GM-Scripte:
       * 0 = nein
       * 1 = Greasemonkey
       * 2 = UserScriptLoader
       * 3 = Scriptish
       */
      gmOrdner: 0,
    
      // CSS-Ordner einbinden: 0 = nein, 1 = ja
      cssOrdner: 0,
    
      /*
       * Ordnernamen exakt an die tatsächlichen Ordnernamen anpassen.
       * Unter Linux ist Groß-/Kleinschreibung relevant.
       */
      cssFolderName: 'CSS',
      cssShadowFolderName: 'CSSShadow',
      cssWebFolderName: 'CSSWeb',
    
      // Aufzurufende about:-Seiten
      abouts: [
        'about:about',
        'about:debugging#/runtime/this-firefox',
        'about:cache',
        'about:config',
        'about:crashes',
        'about:downloads',
        'about:home',
        'about:logins',
        'about:memory',
        'about:support',
        'about:preferences',
        'about:performance',
        'about:profiles'
      ],
    
      // Normale Firefox-Einstellungen anzeigen
      showNormalPrefs: 0,
    
      /*
       * Skriptliste in die Zwischenablage:
       * 0 = nein
       * 1 = ohne Nummerierung
       * 2 = getrennte Nummerierung
       * 3 = gemeinsame Nummerierung
       */
      enableScriptsToClip: 1,
    
      // Neustart-Eintrag erzwingen
      enableRestart: 0,
    
      /*
       * =======================
       * Ende der Konfiguration
       * =======================
       */
    
    
      init: function() {
        var menu;
    
        if (this.warpmenuto.toLowerCase() == 'menu') {
          var zielmenu = document.getElementById('menu_ToolsPopup');
    
          if (!zielmenu) {
            if (typeof userChrome != 'undefined' && userChrome.log) {
              userChrome.log(
                'extras_config_menu.uc.js findet das Zielmenü nicht.'
              );
            }
            return;
          }
    
          menu = zielmenu.appendChild(
            this.createMenuElement(
              'menu',
              'Config Menü',
              'ExtraConfigMenu'
            )
          );
    
          menu.setAttribute('class', 'menu-iconic');
    
          menu.addEventListener('dblclick', function() {
            openTrustedLinkIn('about:config', 'tab');
          });
    
        } else {
          if (window.__SSi == 'window0') {
            CustomizableUI.createWidget({
              id: 'ExtraConfigMenu-button',
              defaultArea: CustomizableUI.AREA_NAVBAR,
              label: 'Extra Config Menü',
              tooltiptext: 'Extra Config Menü\nMittelklick öffnet about:config'
            });
          }
    
          menu = document.getElementById('ExtraConfigMenu-button');
    
          if (!menu) {
            return;
          }
    
          menu.setAttribute('type', 'menu');
    
          menu.addEventListener('click', function(event) {
            if (event.button == 1) {
              openTrustedLinkIn('about:config', 'tab');
            }
          });
        }
    
        var css =
          '#ExtraConfigMenu, #ExtraConfigMenu-button {' +
          '  list-style-image: url(file:///C:/Users/Ramo/AppData/Roaming/' +
          'Mozilla/Firefox/Profiles/c612nnc8.default-release/chrome/Icons/extraConf.png);' +
          '}' +
          '#ExtraConfigMenu-button > dropmarker,' +
          '#ExtraConfigMenu-button > hbox > .toolbarbutton-menu-dropmarker {' +
          '  display: none !important;' +
          '}';
    
        var sss = Cc[
          '@mozilla.org/content/style-sheet-service;1'
        ].getService(Ci.nsIStyleSheetService);
    
        var uri = Services.io.newURI(
          'data:text/css;charset=UTF-8,' + encodeURIComponent(css)
        );
    
        if (!sss.sheetRegistered(uri, sss.AGENT_SHEET)) {
          sss.loadAndRegisterSheet(uri, sss.AGENT_SHEET);
        }
    
        menu.addEventListener('popupshowing', function() {
          uProfMenu.getScripts(0);
          uProfMenu.getCss(3);
          uProfMenu.getCss(4);
          uProfMenu.getCss(5);
        });
    
        var menupopup = menu.appendChild(
          this.createMenuElement(
            'menupopup',
            '',
            'ExtraConfigMenu-popup'
          )
        );
    
        /*
         * UserChromeJS-Scripte
         */
        var submenu = menupopup.appendChild(
          this.createMenuElement('menu', 'Scripte', 'submenu-ucjs')
        );
    
        submenu.appendChild(
          this.createMenuElement(
            'menupopup',
            '',
            'submenu-ucjs-items'
          )
        );
    
        /*
         * CSS
         */
        submenu = menupopup.appendChild(
          this.createMenuElement('menu', 'CSS', 'submenu-css')
        );
    
        submenu.appendChild(
          this.createMenuElement(
            'menupopup',
            '',
            'submenu-css-items'
          )
        );
    
        /*
         * CSSShadow
         */
        submenu = menupopup.appendChild(
          this.createMenuElement(
            'menu',
            'CSSShadow',
            'submenu-CSSShadow'
          )
        );
    
        submenu.appendChild(
          this.createMenuElement(
            'menupopup',
            '',
            'submenu-CSSShadow-items'
          )
        );
    
        /*
         * CSSWeb
         */
        submenu = menupopup.appendChild(
          this.createMenuElement(
            'menu',
            'CSSWeb',
            'submenu-cssweb'
          )
        );
    
        submenu.appendChild(
          this.createMenuElement(
            'menupopup',
            '',
            'submenu-cssweb-items'
          )
        );
    
        /*
         * about:-Seiten
         */
        if (this.abouts.length > 0) {
          menupopup.appendChild(document.createXULElement('menuseparator'));
    
          if (this.abouts[0] == '0') {
            for (var i = 1; i < this.abouts.length; i++) {
              menupopup.appendChild(
                this.createMenuItem(
                  this.abouts[i],
                  function(event) {
                    openTrustedLinkIn(
                      event.currentTarget.getAttribute('data-url'),
                      'tab'
                    );
                  },
                  'uProfMenu_about',
                  {
                    'data-url': this.abouts[i]
                  }
                )
              );
            }
          } else {
            submenu = menupopup.appendChild(
              this.createMenuElement(
                'menu',
                'about-Seiten',
                'submenu-about'
              )
            );
    
            submenu.appendChild(
              this.createMenuElement(
                'menupopup',
                '',
                'submenu-about-items'
              )
            );
    
            this.fillMenu(
              'submenu-about',
              'submenu-about-items',
              'about-Seiten',
              this.abouts,
              'uProfMenu_about',
              1
            );
          }
        }
    
        /*
         * Zwischenablage
         */
        if (this.enableScriptsToClip) {
          menupopup.appendChild(
            this.createMenuItem(
              'Scriptliste in Zwischenablage kopieren',
              function() {
                uProfMenu.getScripts(1);
              },
              'uProfMenu_clipboard'
            )
          );
        }
    
        menupopup.appendChild(
          document.createXULElement('menuseparator')
        );
    
        /*
         * Konfigurationsdateien
         */
        menupopup.appendChild(
          this.createMenuItem(
            'userChrome.css',
            function() {
              uProfMenu.edit(6, 'userChrome.css');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'userChromeShadow.css',
            function() {
              uProfMenu.edit(6, 'userChromeShadow.css');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'userContent.css',
            function() {
              uProfMenu.edit(6, 'userContent.css');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'userChrome.js',
            function() {
              uProfMenu.edit(6, 'userChrome.js');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'prefs.js',
            function() {
              uProfMenu.edit(1, 'prefs.js');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'user.js',
            function() {
              uProfMenu.edit(1, 'user.js');
            },
            'uProfMenu_edit'
          )
        );
    
        menupopup.appendChild(
          document.createXULElement('menuseparator')
        );
    
        /*
         * Ordner
         */
        switch (this.gmOrdner) {
          case 1:
            menupopup.appendChild(
              this.createMenuItem(
                'GM-Scripte',
                function() {
                  uProfMenu.dirOpen(
                    uProfMenu.getPrefDirectoryPath('ProfD') +
                    uProfMenu.getDirSep() +
                    'gm_scripts'
                  );
                },
                'uProfMenu_folder'
              )
            );
            break;
    
          case 2:
            menupopup.appendChild(
              this.createMenuItem(
                'USL-Scripte',
                function() {
                  uProfMenu.dirOpen(
                    uProfMenu.getPrefDirectoryPath('UChrm') +
                    uProfMenu.getDirSep() +
                    'UserScriptLoader'
                  );
                },
                'uProfMenu_folder'
              )
            );
            break;
    
          case 3:
            menupopup.appendChild(
              this.createMenuItem(
                'Scriptish-Scripte',
                function() {
                  uProfMenu.dirOpen(
                    uProfMenu.getPrefDirectoryPath('ProfD') +
                    uProfMenu.getDirSep() +
                    'scriptish_scripts'
                  );
                },
                'uProfMenu_folder'
              )
            );
            break;
        }
    
        menupopup.appendChild(
          this.createMenuItem(
            'Scripte-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('UChrm') +
                uProfMenu.getDirSep() +
                uProfMenu.jsSubfolder
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'CSS-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('UChrm') +
                uProfMenu.getDirSep() +
                uProfMenu.cssFolderName
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'CSSShadow-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('UChrm') +
                uProfMenu.getDirSep() +
                uProfMenu.cssShadowFolderName
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'CSSWeb-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('UChrm') +
                uProfMenu.getDirSep() +
                uProfMenu.cssWebFolderName
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Chrome-Ordner öffnen',
            function() {
              uProfMenu.prefDirOpen('UChrm');
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Profil-Ordner öffnen',
            function() {
              uProfMenu.prefDirOpen('ProfD');
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Icons-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('UChrm') +
                uProfMenu.getDirSep() +
                'Icons'
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Installations-Ordner öffnen',
            function() {
              uProfMenu.prefDirOpen('CurProcD');
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Add-ons-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('ProfD') +
                uProfMenu.getDirSep() +
                'extensions'
              );
            },
            'uProfMenu_folder'
          )
        );
    
        menupopup.appendChild(
          this.createMenuItem(
            'Startup-Cache-Ordner öffnen',
            function() {
              uProfMenu.dirOpen(
                uProfMenu.getPrefDirectoryPath('ProfLD') +
                uProfMenu.getDirSep() +
                'startupCache'
              );
            },
            'uProfMenu_folder'
          )
        );
    
        /*
         * Normale Einstellungen
         */
        if (
          this.abouts.length == 0 &&
          (this.showNormalPrefs ||
           typeof ToolRstartMod != 'undefined')
        ) {
          menupopup.appendChild(
            document.createXULElement('menuseparator')
          );
        }
    
        if (this.showNormalPrefs) {
          menupopup.appendChild(
            this.createMenuItem(
              'Einstellungen',
              function() {
                try {
                  openOptionsDialog();
                } catch (e) {
                  openPreferences();
                }
              },
              'uProfMenu_prefs'
            )
          );
        }
    
        /*
         * Neustart
         */
        if (
          typeof ToolRstartMod != 'undefined' ||
          this.enableRestart
        ) {
          menupopup.appendChild(
            this.createMenuItem(
              'Neustart',
              function() {
                try {
                  ToolRstartMod.restartApp(false);
                } catch (e) {
                  alert(e);
                }
              },
              'uProfMenu_restart'
            )
          );
        }
      },
    
    
      getDirSep: function() {
        var osString = Services.appinfo.OS;
    
        switch (osString) {
          case 'WINNT':
            return '\\';
    
          case 'Linux':
          case 'Darwin':
          default:
            return '/';
        }
      },
    
    
      edit: function(openMode, filename) {
        var dSep = this.getDirSep();
        var path;
    
        switch (openMode) {
          case 0:
            path = this.getPrefDirectoryPath('UChrm');
    
            if (this.jsSubfolder.length != 0) {
              path += dSep + this.jsSubfolder;
            }
    
            path += dSep + filename;
            break;
    
          case 1:
            path =
              this.getPrefDirectoryPath('ProfD') +
              dSep +
              filename;
            break;
    
          case 2:
            path = filename;
            break;
    
          case 3:
            path =
              this.getPrefDirectoryPath('UChrm') +
              dSep +
              this.cssFolderName +
              dSep +
              filename;
            break;
    
          case 4:
            path =
              this.getPrefDirectoryPath('UChrm') +
              dSep +
              this.cssWebFolderName +
              dSep +
              filename;
            break;
    
          case 5:
            path =
              this.getPrefDirectoryPath('UChrm') +
              dSep +
              this.cssShadowFolderName +
              dSep +
              filename;
            break;
    
          case 6:
            path =
              this.getPrefDirectoryPath('UChrm') +
              dSep +
              filename;
            break;
    
          default:
            return;
        }
    
        this.launch(this.TextOpenExe, path);
      },
    
    
      dirOpen: function(path) {
        if (this.vFileManager.length != 0) {
          var file = Cc[
            '@mozilla.org/file/local;1'
          ].createInstance(Ci.nsIFile);
    
          var process = Cc[
            '@mozilla.org/process/util;1'
          ].createInstance(Ci.nsIProcess);
    
          file.initWithPath(this.vFileManager);
          process.init(file);
    
          var args = [path];
          process.run(false, args, args.length);
        } else {
          var dir = Cc[
            '@mozilla.org/file/local;1'
          ].createInstance(Ci.nsIFile);
    
          dir.initWithPath(path);
          dir.launch();
        }
      },
    
    
      prefDirOpen: function(prefDir) {
        var path = this.getPrefDirectoryPath(prefDir);
        this.dirOpen(path);
      },
    
    
      getPrefDirectoryPath: function(prefDir) {
        var file = Services.dirsvc.get(prefDir, Ci.nsIFile);
    
        if (prefDir == 'CurProcD') {
          file = file.parent;
        }
    
        return file.path;
      },
    
    
      launch: function(editorPath, filePath) {
        var file = Cc[
          '@mozilla.org/file/local;1'
        ].createInstance(Ci.nsIFile);
    
        var process = Cc[
          '@mozilla.org/process/util;1'
        ].createInstance(Ci.nsIProcess);
    
        file.initWithPath(editorPath);
    
        /*
         * Falls der konfigurierte Editor nicht existiert,
         * view_source.editor.path verwenden.
         */
        if (!file.exists()) {
          try {
            editorPath = Services.prefs.getStringPref(
              'view_source.editor.path'
            );
          } catch (e) {
            alert(
              'Editor nicht gefunden und view_source.editor.path ist nicht gesetzt.'
            );
            return;
          }
    
          file.initWithPath(editorPath);
        }
    
        if (!file.exists()) {
          alert('Editor nicht gefunden:\n' + editorPath);
          return;
        }
    
        process.init(file);
    
        var args = [filePath];
        process.run(false, args, args.length);
      },
    
    
      stringComparison: function(a, b) {
        function normalize(value) {
          return value
            .toLowerCase()
            .replace(/ä/g, 'a')
            .replace(/ö/g, 'o')
            .replace(/ü/g, 'u')
            .replace(/ß/g, 's');
        }
    
        a = normalize(a);
        b = normalize(b);
    
        return a == b ? 0 : a > b ? 1 : -1;
      },
    
    
      getScripts: function(type) {
        var ucJsScripts = [];
        var folderPath = Services.dirsvc.get(
          'UChrm',
          Ci.nsIFile
        ).path;
    
        if (this.jsSubfolder.length != 0) {
          folderPath +=
            this.getDirSep() +
            this.jsSubfolder;
        }
    
        var folder = Cc[
          '@mozilla.org/file/local;1'
        ].createInstance(Ci.nsIFile);
    
        folder.initWithPath(folderPath);
    
        if (folder.exists() && folder.isDirectory()) {
          var files = folder.directoryEntries;
    
          while (files.hasMoreElements()) {
            var file = files
              .getNext()
              .QueryInterface(Ci.nsIFile);
    
            if (/\.uc\.js$/i.test(file.leafName)) {
              ucJsScripts.push(file.leafName);
            }
          }
        }
    
        if (this.sortScripts) {
          ucJsScripts.sort(this.stringComparison);
        }
    
        if (type == 0) {
          this.fillMenu(
            'submenu-ucjs',
            'submenu-ucjs-items',
            'Meine Scripte',
            ucJsScripts,
            'uProfMenu_ucjs',
            0
          );
        } else {
          var result = this.fillClipboardValue(
            ucJsScripts,
            []
          );
    
          Cc[
            '@mozilla.org/widget/clipboardhelper;1'
          ].getService(Ci.nsIClipboardHelper).copyString(result);
        }
      },
    
    
      getCss: function(type) {
        var cssFiles = [];
        var folderName;
    
        switch (type) {
          case 3:
            folderName = this.cssFolderName;
            break;
    
          case 4:
            folderName = this.cssWebFolderName;
            break;
    
          case 5:
            folderName = this.cssShadowFolderName;
            break;
    
          default:
            return;
        }
    
        var folderPath =
          Services.dirsvc.get('UChrm', Ci.nsIFile).path +
          this.getDirSep() +
          folderName;
    
        var folder = Cc[
          '@mozilla.org/file/local;1'
        ].createInstance(Ci.nsIFile);
    
        folder.initWithPath(folderPath);
    
        if (folder.exists() && folder.isDirectory()) {
          var files = folder.directoryEntries;
    
          while (files.hasMoreElements()) {
            var file = files
              .getNext()
              .QueryInterface(Ci.nsIFile);
    
            if (/\.css$/i.test(file.leafName)) {
              cssFiles.push(file.leafName);
            }
          }
        }
    
        if (this.sortScripts) {
          cssFiles.sort(this.stringComparison);
        }
    
        if (type == 3) {
          this.fillMenu(
            'submenu-css',
            'submenu-css-items',
            'Meine CSS-Dateien',
            cssFiles,
            'uProfMenu_css',
            3
          );
        } else if (type == 4) {
          this.fillMenu(
            'submenu-cssweb',
            'submenu-cssweb-items',
            'Meine CSSWeb-Dateien',
            cssFiles,
            'uProfMenu_css',
            4
          );
        } else if (type == 5) {
          this.fillMenu(
            'submenu-CSSShadow',
            'submenu-CSSShadow-items',
            'Meine CSSShadow-Dateien',
            cssFiles,
            'uProfMenu_css',
            5
          );
        }
      },
    
    
      fillMenu: function(
        submenuId,
        submenuItemsId,
        label,
        fileArray,
        itemClass,
        type
      ) {
        var submenu = document.getElementById(submenuId);
        var popup = document.getElementById(submenuItemsId);
    
        if (!submenu || !popup) {
          return;
        }
    
        submenu.setAttribute(
          'label',
          label + ' (' + fileArray.length + ')'
        );
    
        while (popup.firstChild) {
          popup.removeChild(popup.firstChild);
        }
    
        for (var i = fileArray.length - 1; i >= 0; i--) {
          var filename = fileArray[i];
          var menuitem;
    
          if (type == 0) {
            menuitem = this.createMenuItem(
              filename,
              function(event) {
                var name =
                  event.currentTarget.getAttribute('data-filename');
    
                if (event.button == 1) {
                  uProfMenu.openAtGithub(event, name);
                } else if (event.button == 2) {
                  uProfMenu.openAtGithub(event, name);
                }
              },
              itemClass,
              {
                'data-filename': filename
              }
            );
    
            menuitem.setAttribute(
              'tooltiptext',
              'Linksklick: Bearbeiten\n' +
              'Mittelklick: GitHub öffnen\n' +
              'Rechtsklick: Suche auf GitHub'
            );
    
            menuitem.addEventListener('command', function(event) {
              uProfMenu.edit(
                0,
                event.currentTarget.getAttribute('data-filename')
              );
            });
    
          } else if (type == 1) {
            menuitem = this.createMenuItem(
              filename,
              function(event) {
                openTrustedLinkIn(
                  event.currentTarget.getAttribute('data-url'),
                  'tab'
                );
              },
              itemClass,
              {
                'data-url': filename
              }
            );
    
          } else if (type == 3) {
            menuitem = this.createMenuItem(
              filename,
              function(event) {
                uProfMenu.edit(
                  3,
                  event.currentTarget.getAttribute('data-filename')
                );
              },
              itemClass,
              {
                'data-filename': filename
              }
            );
    
          } else if (type == 4) {
            menuitem = this.createMenuItem(
              filename,
              function(event) {
                uProfMenu.edit(
                  4,
                  event.currentTarget.getAttribute('data-filename')
                );
              },
              itemClass,
              {
                'data-filename': filename
              }
            );
    
          } else if (type == 5) {
            menuitem = this.createMenuItem(
              filename,
              function(event) {
                uProfMenu.edit(
                  5,
                  event.currentTarget.getAttribute('data-filename')
                );
              },
              itemClass,
              {
                'data-filename': filename
              }
            );
          }
    
          if (menuitem) {
            popup.insertBefore(menuitem, popup.firstChild);
          }
        }
      },
    
    
      fillClipboardValue: function(scriptArray, xulArray) {
        var scriptCount = scriptArray.length;
        var xulCount = xulArray.length;
        var result;
    
        switch (this.enableScriptsToClip) {
          case 1:
            result =
              'userChromeJS/uc.js (' +
              scriptCount +
              '):\n' +
              '------------------------\n' +
              scriptArray.join('\n') +
              '\n\n' +
              'userChromeJS/uc.xul (' +
              xulCount +
              '):\n' +
              '-------------------------\n' +
              xulArray.join('\n');
            break;
    
          case 2:
          case 3:
            result =
              'userChromeJS/uc.js (' +
              scriptCount +
              '):\n' +
              '------------------------';
    
            for (var i = 0; i < scriptCount; i++) {
              result += '\n' + (i + 1) + '. ' + scriptArray[i];
            }
    
            result +=
              '\n\nuserChromeJS/uc.xul (' +
              xulCount +
              '):\n' +
              '-------------------------';
    
            for (var j = 0; j < xulCount; j++) {
              var number = j + 1;
    
              if (this.enableScriptsToClip == 3) {
                number += scriptCount;
              }
    
              result += '\n' + number + '. ' + xulArray[j];
            }
            break;
    
          default:
            result = '';
        }
    
        return result;
      },
    
    
      createMenuElement: function(type, label, id) {
        var element = document.createXULElement(type);
    
        if (label) {
          element.setAttribute('label', label);
        }
    
        if (id) {
          element.setAttribute('id', id);
        }
    
        return element;
      },
    
    
      createMenuItem: function(label, callback, className, attributes) {
        var item = document.createXULElement('menuitem');
    
        item.setAttribute('label', label);
    
        if (className) {
          item.setAttribute('class', className);
        }
    
        if (attributes) {
          for (var name in attributes) {
            item.setAttribute(name, attributes[name]);
          }
        }
    
        /*
         * Kein oncommand-Attribut und kein Inline-JavaScript:
         * Die Funktion wird direkt als Event-Listener registriert.
         */
        item.addEventListener('command', callback);
    
        /*
         * Für Mittelklick und Rechtsklick wird zusätzlich das click-Event
         * verwendet. Der normale Linksklick läuft über command.
         */
        item.addEventListener('click', callback);
    
        return item;
      },
    
    
      openAtGithub: function(event, scriptName) {
        if (event.button == 1) {
          var githubUrl =
            'https://github.com/ardiman/userChrome.js/tree/master/' +
            this.cleanFileName(scriptName);
    
          openWebLinkIn(githubUrl, 'tab');
    
        } else if (event.button == 2) {
          event.preventDefault();
    
          var searchUrl =
            'https://github.com/search?langOverride=&language=&q=' +
            encodeURIComponent(scriptName) +
            '&repo=&start_value=1&type=Code';
    
          openWebLinkIn(searchUrl, 'tab');
        }
      },
    
    
      cleanFileName: function(name) {
        name = name.toLowerCase();
    
        var expressions = [
          /\.uc\.js$/,
          /\.uc\.xul$/,
          /^ucjs_/,
          /_\d.+/,
          /_fx\d+/,
          /[-+\.]/g,
          /_v\d+/
        ];
    
        for (var i = 0; i < expressions.length; i++) {
          name = name.replace(expressions[i], '');
        }
    
        return name;
      }
    };
    
    
    /*
     * Script starten
     */
    uProfMenu.init();
    Alles anzeigen
  • extra_config_menu.uc.js > ohne security.allow_unsafe_dangerous_privileged_evil_eval auf false

    • FuchsFan
    • 11. August 2026 um 19:08
    Zitat von Mira_Belle

    Funktioniert hier bei mir sowohl in der Final, als auch in der Nighty.

    Anderes Profil genommen, jetzt funktioniert es auch, also alles gut.

  • extra_config_menu.uc.js > ohne security.allow_unsafe_dangerous_privileged_evil_eval auf false

    • FuchsFan
    • 11. August 2026 um 18:59
    Zitat von Mira_Belle

    Mh, ....
    War dieser Menüpunkt denn im ursprünglichen Skript vorhanden?

    Ja, aber in Zeile 29 muss dann die 1 aktiviert werden, hatte ich auch i.M. nicht mehr auf dem Schirm.

  • extra_config_menu.uc.js > ohne security.allow_unsafe_dangerous_privileged_evil_eval auf false

    • FuchsFan
    • 11. August 2026 um 18:09
    Zitat von Mira_Belle

    ch habe das Skript insofern geändert, dass
    a. die userChromeShadow.uc.js nicht mehr "eingebunden" wird!

    Dann müsstest du das bei allen anderen auch so machen. Wer sich auf's Glatteis begibt, der sollte wissen was er macht.;)

    Zitat von Mira_Belle

    Auch ich halte das Chromeverzeichnis sauber und habe die Userskripte unter chrome/scripts

    Ich habe in Nightly getestet, aber im Submenü "Meine Scripte" werden nur aus dem Ordner chrome die Scripte aufgelistet. Obwohl in der userChrome.js das userChrome.import("scripts", "UChrm"); vorgegeben ist, und auch alle Scripte geladen werden.

    Und dann fehlt "Neustart" ganz.

  • extra_config_menu.uc.js > ohne security.allow_unsafe_dangerous_privileged_evil_eval auf false

    • FuchsFan
    • 11. August 2026 um 08:47

    Endor

    Wenn ich mich mal einmischen darf, Mira hat ja geschrieben, dass wir am Original festhalten sollten, und das hat sie gemacht. In #2 hatte ich ja angekündigt, dass das Script angepasst wurde, damit Scripte auch aus dem Ordner "Scripte" aufgerufen werden können. So habe ich das z.B. bei mir, um den Ordner chrome "sauber" zu halten. Also ist schon i.O. so, wenn du Miras Script genommen hast.:thumbup:

  • extra_config_menu.uc.js > ohne security.allow_unsafe_dangerous_privileged_evil_eval auf false

    • FuchsFan
    • 10. August 2026 um 17:49
    Zitat von Endor

    Habe jetzt Mira_Belles Version genommen.
    Werde diese dann auch bei Github hochladen.

    Aber gewiss doch, ich habe für mich eine erweiterte Version, das war nur ein Versuch ob es gelingt das Script so lauffähig zu bekommen. Will hoffen dass wir omar1979 nicht ganz wuschelig gemacht haben, aber er kann ja weitere Hilfe erwarten.

  • extra_config_menu.uc.js > ohne security.allow_unsafe_dangerous_privileged_evil_eval auf false

    • FuchsFan
    • 10. August 2026 um 15:07
    Zitat von Mira_Belle

    Wie Du leicht erkennen kannst habe ich eine kleine Korrektur in Zeile 52 eingebaut.

    Das War auch der Fehler, nun funktioniert es ohne.:thumbup:

  • extra_config_menu.uc.js > ohne security.allow_unsafe_dangerous_privileged_evil_eval auf false

    • FuchsFan
    • 10. August 2026 um 14:49

    Das stimmt, jetzt aus Version 153:

    Uncaught TypeError: can't access property "setAttribute", menu is null   init file:///G:/Portable.Firefox.Updater.1/Firefox Stable x64/profile/chrome/Scripte/04_extras_config_menu3.uc.js:50   <anonymous> file:///G:/Portable.Firefox.Updater.1/Firefox Stable x64/profile/chrome/Scripte/04_extras_config_menu3.uc.js:499   loadScript file:///G:/Portable.Firefox.Updater.1/Firefox Stable x64/userChromeJS/utilities.js:11404_extras_config_menu3.uc.js:50:7

  • extra_config_menu.uc.js > ohne security.allow_unsafe_dangerous_privileged_evil_eval auf false

    • FuchsFan
    • 10. August 2026 um 14:38
    Zitat von 2002Andreas

    Hier schon:

    Im Nightly ohne Fehler.:/

Unterstütze uns!

Jährlich (2026)

72,4 %

72,4% (560,79 von 775 EUR)

Jetzt spenden
  1. Kontakt
  2. Datenschutz
  3. Impressum
Community-Software: WoltLab Suite™
Mastodon