From f6498474c3b9e0b7770e0221755f3c91922e6b0a Mon Sep 17 00:00:00 2001
From: ulrich
Date: Wed, 14 Apr 2021 20:48:35 +0000
Subject: [PATCH] Zoom unterbunden

---
 src/de/uhilger/mediaz/Server.java |   10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/src/de/uhilger/mediaz/Server.java b/src/de/uhilger/mediaz/Server.java
index 69228eb..2f71fc9 100644
--- a/src/de/uhilger/mediaz/Server.java
+++ b/src/de/uhilger/mediaz/Server.java
@@ -21,6 +21,7 @@
 import de.uhilger.mediaz.api.FileHandler;
 import de.uhilger.mediaz.api.ListFileHandler;
 import de.uhilger.mediaz.api.ListHandler;
+import de.uhilger.mediaz.api.MediaSteuerung;
 import de.uhilger.mediaz.api.StopServerHandler;
 import de.uhilger.mediaz.api.StorageHandler;
 import de.uhilger.mediaz.store.FileStorage;
@@ -49,12 +50,13 @@
   public static final String RB_SERVER_START_MSG = "msgServerStart";
   public static final String RB_WEBROOT = "webroot";
   public static final String RB_STORE = "store";
+  public static final String RB_STRG = "strg";
   public static final String RB_ALIST= "alist";
   //public static final String RB_UI_ROOT = "uiroot";
   public static final String RB_STOP_SERVER = "stopServer";
   //public static final String RB_ABLAGE_TEST = "testAblage";
   //public static final String RB_STORE_TEST = "testStore";
-  public static final String RB_SLASH = "slash";
+  public static final String SLASH = "/";
 
   private int port;
 
@@ -85,9 +87,8 @@
    * @param ctxName Name des Kontexts, unter dem der Server aufrufbar sein soll
    */
   public void setContextName(String ctxName) {
-    String slash = App.getRs(RB_SLASH);
-    if (!ctxName.startsWith(slash)) {
-      this.ctx = slash + ctxName;
+    if (!ctxName.startsWith(SLASH)) {
+      this.ctx = SLASH + ctxName;
     } else {
       this.ctx = ctxName;
     }
@@ -111,6 +112,7 @@
     server.createContext(ctx + App.getRs(RB_WEBROOT), new FileHandler(wwwDir.getAbsolutePath()));
     ablageorteEinklinken(server);
     server.createContext(ctx + App.getRs(RB_STORE), new StorageHandler());
+    server.createContext(ctx + App.getRs(RB_STRG), new MediaSteuerung());
     server.createContext(ctx + App.getRs(RB_ALIST), new ListHandler());
     server.createContext(ctx + App.getRs(RB_STOP_SERVER), new StopServerHandler());
     server.setExecutor(Executors.newFixedThreadPool(20));

--
Gitblit v1.9.3