Reenable logging socket messages before debug mode

Signed-off-by: Neil Guertin <neil.guertin@collabora.com>
Change-Id: I2452d4c7e3e3152533b676fb2db81ef95d96fb54
This commit is contained in:
Neil Guertin 2024-02-08 09:31:53 -05:00 committed by Szymon Kłos
parent 474ff7612b
commit e0c5c85718
2 changed files with 4 additions and 2 deletions

View file

@ -24,6 +24,7 @@ L.DebugManager = L.Class.extend({
initialize: function(map) {
this._map = map;
this.debugOn = false;
this.debugNeverStarted = true;
},
toggle: function() {
@ -42,6 +43,7 @@ L.DebugManager = L.Class.extend({
this._painter = this._map._docLayer._painter;
this.debugOn = true;
this.debugNeverStarted = false;
this._controls = {};
// Add header

View file

@ -176,7 +176,7 @@ app.definitions.Socket = L.Class.extend({
},
_doSend: function(msg) {
if (this._map._debug.logOutgoingMessages) {
if (this._map._debug.debugNeverStarted || this._map._debug.logOutgoingMessages) {
// Only attempt to log text frames, not binary ones.
if (typeof msg === 'string')
this._logSocket('OUTGOING', msg);
@ -563,7 +563,7 @@ app.definitions.Socket = L.Class.extend({
textMsg = e.textMsg;
imgBytes = e.imgBytes;
if (this._map._debug.logIncomingMessages) {
if (this._map._debug.debugNeverStarted || this._map._debug.logIncomingMessages) {
this._logSocket('INCOMING', textMsg);
}