aboutsummaryrefslogtreecommitdiffstats
path: root/src/net/java/sip
diff options
context:
space:
mode:
authorDanny van Heumen <danny@dannyvanheumen.nl>2014-08-21 22:56:27 +0200
committerDanny van Heumen <danny@dannyvanheumen.nl>2014-08-21 22:56:27 +0200
commit9be99cdeb2941dcc987fa939ad3ebd55a6d54507 (patch)
tree7fd2e35d5970e5078586dcfb30996534af81a0b8 /src/net/java/sip
parent29953c199f846bb485ada88dec0a427dfe213f52 (diff)
downloadjitsi-9be99cdeb2941dcc987fa939ad3ebd55a6d54507.zip
jitsi-9be99cdeb2941dcc987fa939ad3ebd55a6d54507.tar.gz
jitsi-9be99cdeb2941dcc987fa939ad3ebd55a6d54507.tar.bz2
Modified default chat room auto-open behaviour to OPEN_ON_MESSAGE.
Diffstat (limited to 'src/net/java/sip')
-rw-r--r--src/net/java/sip/communicator/impl/gui/main/chat/conference/ChatRoomAutoOpenConfigDialog.java2
-rw-r--r--src/net/java/sip/communicator/impl/gui/main/chat/conference/ConferenceChatManager.java5
-rw-r--r--src/net/java/sip/communicator/impl/muc/MUCCustomContactActionService.java6
-rw-r--r--src/net/java/sip/communicator/service/muc/MUCService.java14
4 files changed, 18 insertions, 9 deletions
diff --git a/src/net/java/sip/communicator/impl/gui/main/chat/conference/ChatRoomAutoOpenConfigDialog.java b/src/net/java/sip/communicator/impl/gui/main/chat/conference/ChatRoomAutoOpenConfigDialog.java
index 410ce7b..88cb77d 100644
--- a/src/net/java/sip/communicator/impl/gui/main/chat/conference/ChatRoomAutoOpenConfigDialog.java
+++ b/src/net/java/sip/communicator/impl/gui/main/chat/conference/ChatRoomAutoOpenConfigDialog.java
@@ -228,7 +228,7 @@ public class ChatRoomAutoOpenConfigDialog
propertyListener);
if(value == null)
- value = MUCService.OPEN_ON_IMPORTANT_MESSAGE;
+ value = MUCService.DEFAULT_AUTO_OPEN_BEHAVIOUR;
if(value.equals(MUCService.OPEN_ON_ACTIVITY))
{
diff --git a/src/net/java/sip/communicator/impl/gui/main/chat/conference/ConferenceChatManager.java b/src/net/java/sip/communicator/impl/gui/main/chat/conference/ConferenceChatManager.java
index 57ec2c1..b4f2abd 100644
--- a/src/net/java/sip/communicator/impl/gui/main/chat/conference/ConferenceChatManager.java
+++ b/src/net/java/sip/communicator/impl/gui/main/chat/conference/ConferenceChatManager.java
@@ -24,9 +24,8 @@ import net.java.sip.communicator.service.protocol.globalstatus.*;
import net.java.sip.communicator.util.*;
import net.java.sip.communicator.util.Logger;
-import org.jitsi.util.*;
-
import org.jdesktop.swingworker.SwingWorker;
+import org.jitsi.util.*;
import org.osgi.framework.*;
/**
@@ -214,7 +213,7 @@ public class ConferenceChatManager
sourceChatRoom.getParentProvider(),
sourceChatRoom.getIdentifier());
if(autoOpenConfig == null)
- autoOpenConfig = MUCService.OPEN_ON_IMPORTANT_MESSAGE;
+ autoOpenConfig = MUCService.DEFAULT_AUTO_OPEN_BEHAVIOUR;
if(autoOpenConfig.equals(MUCService.OPEN_ON_ACTIVITY)
|| (autoOpenConfig.equals(MUCService.OPEN_ON_MESSAGE)
diff --git a/src/net/java/sip/communicator/impl/muc/MUCCustomContactActionService.java b/src/net/java/sip/communicator/impl/muc/MUCCustomContactActionService.java
index 1dac544..97a2ca1 100644
--- a/src/net/java/sip/communicator/impl/muc/MUCCustomContactActionService.java
+++ b/src/net/java/sip/communicator/impl/muc/MUCCustomContactActionService.java
@@ -8,8 +8,6 @@ package net.java.sip.communicator.impl.muc;
import java.util.*;
-import org.jitsi.service.resources.*;
-
import net.java.sip.communicator.plugin.desktoputil.chat.*;
import net.java.sip.communicator.service.contactsource.*;
import net.java.sip.communicator.service.customcontactactions.*;
@@ -17,6 +15,8 @@ import net.java.sip.communicator.service.muc.*;
import net.java.sip.communicator.service.protocol.*;
import net.java.sip.communicator.util.*;
+import org.jitsi.service.resources.*;
+
/**
* Implements <tt>CustomContactActionsService</tt> for MUC contact source.
*
@@ -643,7 +643,7 @@ public class MUCCustomContactActionService
((ChatRoomSourceContact)actionSource).getProvider(),
((ChatRoomSourceContact)actionSource).getChatRoomID());
if(openAutomaticallyValue == null)
- openAutomaticallyValue = MUCService.OPEN_ON_IMPORTANT_MESSAGE;
+ openAutomaticallyValue = MUCService.DEFAULT_AUTO_OPEN_BEHAVIOUR;
String openAutomaticallyKey = MUCService.autoOpenConfigValuesTexts
.get(openAutomaticallyValue);
return "<html>" + text + "...<br><font size=\"2\"><center> ("
diff --git a/src/net/java/sip/communicator/service/muc/MUCService.java b/src/net/java/sip/communicator/service/muc/MUCService.java
index 8b5b9da..1fb75bf 100644
--- a/src/net/java/sip/communicator/service/muc/MUCService.java
+++ b/src/net/java/sip/communicator/service/muc/MUCService.java
@@ -27,6 +27,11 @@ public abstract class MUCService
= "net.java.sip.communicator.impl.muc.MUC_SERVICE_DISABLED";
/**
+ * Key for auto-open configuration entry.
+ */
+ private static String AUTO_OPEN_CONFIG_KEY = "openAutomatically";
+
+ /**
* The value for chat room configuration property to open automatically on
* activity
*/
@@ -45,6 +50,11 @@ public abstract class MUCService
public static String OPEN_ON_IMPORTANT_MESSAGE = "on_important_message";
/**
+ * The default for chat room auto-open behaviour.
+ */
+ public static String DEFAULT_AUTO_OPEN_BEHAVIOUR = OPEN_ON_MESSAGE;
+
+ /**
* Map for the auto open configuration values and their text representation
*/
public static Map<String, String> autoOpenConfigValuesTexts
@@ -73,7 +83,7 @@ public abstract class MUCService
{
ConfigurationUtils.updateChatRoomProperty(
pps,
- chatRoomId, "openAutomatically", value);
+ chatRoomId, AUTO_OPEN_CONFIG_KEY, value);
}
/**
@@ -88,7 +98,7 @@ public abstract class MUCService
{
return ConfigurationUtils.getChatRoomProperty(
pps,
- chatRoomId, "openAutomatically");
+ chatRoomId, AUTO_OPEN_CONFIG_KEY);
}
/**