[Notification Jobs] Enforce plain text and escape HTML
ClosedPublic

Authored by davidedmundson on Apr 27 2017, 10:22 AM.

Details

Reviewers
mart
broulik
Group Reviewers
Plasma
Summary

QtQuick Text auto-interprets HTML tags when it finds them, this can lead to unexpected results if a file is named e.g. <h1>foo</h1>.

Since notifications do interpret HTML tags by design, we manually escape them there.

Test Plan

Copied a file <h1>foo</h1> and no longer got huge text in summary, details, and finish popup. Verified that speed and ETA label still works.

5.8 branch?

Diff Detail

Repository
R120 Plasma Workspace
Lint
Lint Skipped
Unit
Unit Tests Skipped
broulik created this revision.Apr 27 2017, 10:22 AM
Restricted Application added a project: Plasma. · View Herald TranscriptApr 27 2017, 10:22 AM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
mart accepted this revision.Apr 27 2017, 11:55 AM
This revision is now accepted and ready to land.Apr 27 2017, 11:55 AM
davidedmundson requested changes to this revision.May 10 2017, 2:00 PM
davidedmundson added a subscriber: davidedmundson.

Since notifications do interpret HTML tags by design, we manually escape them there.

I don't know hwat you mean.

tags are important, we have notifications with links and emoticons.

Copied a file <h1>foo</h1> and no longer got huge text in summary, details, and finish popup. Verified that speed and ETA label still works.

That needs fixing before sending a notification. Not in the UI.

This revision now requires changes to proceed.May 10 2017, 2:00 PM
davidedmundson accepted this revision.May 10 2017, 2:00 PM

Edit.Didn't see this was the job delegate.

Carry on.

This revision is now accepted and ready to land.May 10 2017, 2:00 PM
davidedmundson commandeered this revision.May 11 2017, 10:41 AM
davidedmundson closed this revision.
davidedmundson edited reviewers, added: broulik; removed: davidedmundson.

submitted.