Correctly read floating point values in CSS.

[GB.FORM.HTMLVIEW]
* BUG: Correctly read floating point values in CSS.
* NEW: Only left mouse button is taken into account by the view when clicking on it. The other buttons are ignored by default.
This commit is contained in:
gambas 2022-01-28 23:57:54 +01:00
parent 742244fe34
commit 47742d7f90
2 changed files with 9 additions and 9 deletions

View file

@ -104,7 +104,7 @@ Public Sub View_MouseDown()
$iLastX = Mouse.X $iLastX = Mouse.X
$iLastY = Mouse.Y $iLastY = Mouse.Y
$hDoc.OnMouseDown(($iLastX + $hView.ScrollX) / $fZoom, ($iLastY + $hView.ScrollY) / $fZoom) If Mouse.Left Then $hDoc.OnMouseDown(($iLastX + $hView.ScrollX) / $fZoom, ($iLastY + $hView.ScrollY) / $fZoom)
End End
@ -112,11 +112,10 @@ Public Sub View_MouseUp()
$iLastX = Mouse.X $iLastX = Mouse.X
$iLastY = Mouse.Y $iLastY = Mouse.Y
$hDoc.OnMouseUp(($iLastX + $hView.ScrollX) / $fZoom, ($iLastY + $hView.ScrollY) / $fZoom) If Mouse.Left Then $hDoc.OnMouseUp(($iLastX + $hView.ScrollX) / $fZoom, ($iLastY + $hView.ScrollY) / $fZoom)
End End
Public Sub View_Scroll() Public Sub View_Scroll()
$hDoc.OnMouseMove(($iLastX + $hView.ScrollX) / $fZoom, ($iLastY + $hView.ScrollY) / $fZoom) $hDoc.OnMouseMove(($iLastX + $hView.ScrollX) / $fZoom, ($iLastY + $hView.ScrollY) / $fZoom)

View file

@ -180,16 +180,17 @@ double litehtml::strtod(const char *nptr, char **endptr)
p = nptr; p = nptr;
if (*p == '+') if (*p == '-')
{
neg = false;
p++;
}
else if (*p == '-')
{ {
neg = true; neg = true;
p++; p++;
} }
else
{
neg = false;
if (*p == '+')
p++;
}
while (*p) while (*p)
{ {