How to display Start and END of an event
-
- Posts: 6432
- Joined: February 3rd, 2009, 6:29 pm
Re: How to display Start and END of an event
You're welcome.
-
- Posts: 24
- Joined: August 25th, 2014, 6:21 am
Re: How to display Start and END of an event
hi,
Following an update of thunderbird, display of Start and EndTime is not working anymore in monthview with the previous hack.
I can still find a file calendar-month-view.js in omni.ja, but once edited, there is no more "startTime" or "endTime", so I don't find a way to modify for the result expected.
Any ideas to proceed?
edit: for an agenda software like "EssentialPIM", in settings, there is a choice : "show for appointments : start & end time"
Following an update of thunderbird, display of Start and EndTime is not working anymore in monthview with the previous hack.
I can still find a file calendar-month-view.js in omni.ja, but once edited, there is no more "startTime" or "endTime", so I don't find a way to modify for the result expected.
Any ideas to proceed?
edit: for an agenda software like "EssentialPIM", in settings, there is a choice : "show for appointments : start & end time"
-
- Posts: 6432
- Joined: February 3rd, 2009, 6:29 pm
Re: How to display Start and END of an event
Try this:
I did not test the hack with Thunderbird 102.
Reference
http://searchfox.org/comm-esr91/search? ... &path=view
http://searchfox.org/comm-esr102/search ... &path=view
Code: Select all
parentTime.isDate = false;
+ var _startTime = val.startDate.getInTimezone(this.parentBox.date.timezone);
+ var _endTime = val.endDate.getInTimezone(this.parentBox.date.timezone);
Code: Select all
- this.timeLabel.textContent = displayTime;
+ if (typeof _startTime === "undefined" || typeof _endTime === "undefined") {
+ this.timeLabel.textContent = displayTime;
+ } else {
+ this.timeLabel.textContent = cal.dtz.formatter.formatTime(_startTime) + " " + cal.dtz.formatter.formatTime(_endTime);
+ }
Reference
http://searchfox.org/comm-esr91/search? ... &path=view
http://searchfox.org/comm-esr102/search ... &path=view
-
- Posts: 24
- Joined: August 25th, 2014, 6:21 am
Re: How to display Start and END of an event
Hi morat,
thanks for your interest.
I'm using TB 102.
Accordind to your message, I tried these changes in calendar-month-view.js :
saved in omni.ja, then replaced, then : thunderbird.exe -purgecaches
but no change in the time display (no errors also), as timelabel doesn't seem to take into account starttime and endtime
thanks for your interest.
I'm using TB 102.
Accordind to your message, I tried these changes in calendar-month-view.js :
Code: Select all
// Convert to the date-time for the start of the day.
parentTime.isDate = false;
+ var _startTime = val.startDate.getInTimezone(this.parentBox.date.timezone);
+ var _endTime = val.endDate.getInTimezone(this.parentBox.date.timezone);
Code: Select all
if (displayTime) {
- this.timeLabel.textContent = displayTime;
+ if (typeof _startTime === "undefined" || typeof _endTime === "undefined") {
+ this.timeLabel.textContent = displayTime;
+ } else {
+ this.timeLabel.textContent = cal.dtz.formatter.formatTime(_startTime) + " " + cal.dtz.formatter.formatTime(_endTime);
+ }
but no change in the time display (no errors also), as timelabel doesn't seem to take into account starttime and endtime
-
- Posts: 6432
- Joined: February 3rd, 2009, 6:29 pm
Re: How to display Start and END of an event
The hack works here.
Screenshot
http://imgur.com/a/rr5KfQG
Tested with:
Thunderbird Portable 102.4.0 (fresh install)
Windows 10 Pro 21H2 32-bit
I edited the omni.ja file using command prompt like so...
AFAICT, the omni.ja file is a normal zip file. (not optimized)
Here is how to view the calendar-month-view.js file using the error console.
P.S.
Can you get the following hack to work?
I assume you know how to edit the calendar-month-view.js file using my hacks.
* don't change lines preceded by space character
* remove lines preceded by minus sign
* add lines preceded by plus sign
Remember to remove the leading plus sign in the added lines.
Screenshot
http://imgur.com/a/rr5KfQG
Tested with:
Thunderbird Portable 102.4.0 (fresh install)
Windows 10 Pro 21H2 32-bit
I edited the omni.ja file using command prompt like so...
Code: Select all
cd /d C:\ThunderbirdPortable\App\Thunderbird
unzip.exe -l omni.ja | find "calendar-month-view.js"
unzip.exe omni.ja chrome\calendar\content\calendar-month-view.js
notepad.exe chrome\calendar\content\calendar-month-view.js
zip.exe omni.ja chrome\calendar\content\calendar-month-view.js
C:\ThunderbirdPortable\ThunderbirdPortable.exe -purgecaches
Here is how to view the calendar-month-view.js file using the error console.
Code: Select all
document.getElementById("tabmail").openTab("contentTab", {
url: "view-source:chrome://calendar/content/calendar-month-view.js",
});
Can you get the following hack to work?
Code: Select all
if (displayTime) {
- this.timeLabel.textContent = displayTime;
+ this.timeLabel.textContent = displayTime + " XXX";
* don't change lines preceded by space character
* remove lines preceded by minus sign
* add lines preceded by plus sign
Remember to remove the leading plus sign in the added lines.
-
- Posts: 24
- Joined: August 25th, 2014, 6:21 am
Re: How to display Start and END of an event
Hi morat,
it works well.
So thank you, your are so helpful.
I apoligise because I probably make a wrong copy the first time and didn't crosscheck, my mistake.
it works well.
So thank you, your are so helpful.
I apoligise because I probably make a wrong copy the first time and didn't crosscheck, my mistake.
-
- Posts: 6432
- Joined: February 3rd, 2009, 6:29 pm
Re: How to display Start and END of an event
You're welcome.