diff options
Diffstat (limited to 'src/ui')
-rw-r--r-- | src/ui/documentwidget.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/ui/documentwidget.c b/src/ui/documentwidget.c index 6524d454..962ccc3b 100644 --- a/src/ui/documentwidget.c +++ b/src/ui/documentwidget.c | |||
@@ -2623,8 +2623,9 @@ static iBool handleCommand_DocumentWidget_(iDocumentWidget *d, const char *cmd) | |||
2623 | } | 2623 | } |
2624 | else if (equal_Command(cmd, "server.trustcert") && document_App() == d) { | 2624 | else if (equal_Command(cmd, "server.trustcert") && document_App() == d) { |
2625 | const iRangecc host = urlHost_String(d->mod.url); | 2625 | const iRangecc host = urlHost_String(d->mod.url); |
2626 | const uint16_t port = urlPort_String(d->mod.url); | ||
2626 | if (!isEmpty_Block(d->certFingerprint) && !isEmpty_Range(&host)) { | 2627 | if (!isEmpty_Block(d->certFingerprint) && !isEmpty_Range(&host)) { |
2627 | setTrusted_GmCerts(certs_App(), host, d->certFingerprint, &d->certExpiry); | 2628 | setTrusted_GmCerts(certs_App(), host, port, d->certFingerprint, &d->certExpiry); |
2628 | d->certFlags |= trusted_GmCertFlag; | 2629 | d->certFlags |= trusted_GmCertFlag; |
2629 | postCommand_Widget(w, "document.info"); | 2630 | postCommand_Widget(w, "document.info"); |
2630 | updateTrust_DocumentWidget_(d, NULL); | 2631 | updateTrust_DocumentWidget_(d, NULL); |
@@ -3993,7 +3994,8 @@ static void drawBannerRun_DrawContext_(iDrawContext *d, const iGmRun *run, iInt2 | |||
3993 | if (certFlags & timeVerified_GmCertFlag && certFlags & domainVerified_GmCertFlag) { | 3994 | if (certFlags & timeVerified_GmCertFlag && certFlags & domainVerified_GmCertFlag) { |
3994 | iUrl parts; | 3995 | iUrl parts; |
3995 | init_Url(&parts, d->widget->mod.url); | 3996 | init_Url(&parts, d->widget->mod.url); |
3996 | const iTime oldUntil = domainValidUntil_GmCerts(certs_App(), parts.host); | 3997 | const iTime oldUntil = |
3998 | domainValidUntil_GmCerts(certs_App(), parts.host, port_Url(&parts)); | ||
3997 | iDate exp; | 3999 | iDate exp; |
3998 | init_Date(&exp, &oldUntil); | 4000 | init_Date(&exp, &oldUntil); |
3999 | iTime now; | 4001 | iTime now; |
@@ -4192,7 +4194,7 @@ static void drawRun_DrawContext_(void *context, const iGmRun *run) { | |||
4192 | height_Rect(run->visBounds), | 4194 | height_Rect(run->visBounds), |
4193 | tmQuoteIcon_ColorId); | 4195 | tmQuoteIcon_ColorId); |
4194 | } | 4196 | } |
4195 | drawBoundRange_Text(run->font, visPos, width_Rect(run->bounds), fg, run->text); | 4197 | drawRange_Text(run->font, visPos, /*width_Rect(run->bounds),*/ fg, run->text); |
4196 | runDrawn:; | 4198 | runDrawn:; |
4197 | } | 4199 | } |
4198 | /* Presentation of links. */ | 4200 | /* Presentation of links. */ |
@@ -4324,8 +4326,8 @@ static void drawRun_DrawContext_(void *context, const iGmRun *run) { | |||
4324 | } | 4326 | } |
4325 | } | 4327 | } |
4326 | } | 4328 | } |
4327 | // drawRect_Paint(&d->paint, (iRect){ visPos, run->bounds.size }, green_ColorId); | 4329 | drawRect_Paint(&d->paint, (iRect){ visPos, run->bounds.size }, green_ColorId); |
4328 | // drawRect_Paint(&d->paint, (iRect){ visPos, run->visBounds.size }, red_ColorId); | 4330 | drawRect_Paint(&d->paint, (iRect){ visPos, run->visBounds.size }, red_ColorId); |
4329 | } | 4331 | } |
4330 | 4332 | ||
4331 | static int drawSideRect_(iPaint *p, iRect rect) { | 4333 | static int drawSideRect_(iPaint *p, iRect rect) { |