Commit graph

78 commits

Author SHA1 Message Date
Martin Robinson
6259df5e2d Update to euclid 0.8 2016-08-12 03:12:06 +02:00
Lars Bergstrom
ecabb1823b Remove clipboard crate to due disallowed usage of GPL code 2016-07-20 11:44:55 -05:00
Josh Matthews
6496d73210 Make textinput handle actual key values. Don't restrict character values to a single byte. 2016-07-06 00:10:24 -04:00
mrmiywj
46cadfdd2c use less repetitive name 2016-06-12 12:28:07 +08:00
Jack Moffitt
568d454ca6 Make Servo DPI aware on Windows
This implements system level DPI awareness for Windows. It has three
parts:

1. Add a application manifest which is copied alongside servo.exe during
build that declares our DPI awareness level. This is needed otherwise
DPI queries will return 96dpi and our application will be upscaled on
high DPI displays.

2. Rename hidpi_factor to avoid confusion with Glutin's hidpi_factor
which does something else.

3. Correctly convert windows sizes on window creation for
Windows. Unlike OS X, Windows uses device pixels for window creation.
2016-05-20 23:40:39 -06:00
Michael Howell
c9cb4839e4 No more headless compositor. Just the normal one.
This changes headless operation to strictly be a runtime option, rather
than a compile-time one. Note that the old headless version still relied
on a display server to support WebGL, while it now requires one all the
time.

Fixes #8573
2016-03-24 11:18:54 -07:00
Patrick Walton
c2581d5cef compositing: In borderless mode, don't show the window until the page
has loaded.

This avoids a flash of unstyled content, which looks especially bad in
browser.html since unstyled content is white and browser.html has a
transparent background.

Closes #9996.
2016-03-15 22:07:21 -07:00
Anthony Ramine
290694b27e Move util::cursor to style_traits 2016-02-16 00:50:01 +01:00
rohan.prinja
1f02c4ebbb task -> thread 2016-01-10 17:58:13 +09:00
bors-servo
8b95d7b8d8 Auto merge of #8757 - servo:skia, r=mbrubeck
Use skia and deps from crates.io.

This makes the initial download for skia go from a 300 MB git repository to a 5 MB tarball. This should help with issues like #6132 and #7687.

Fix https://github.com/servo/skia/issues/70

This builds, but the at the moment causes a number of tidy errors for duplicated crates.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8757)
<!-- Reviewable:end -->
2015-12-03 12:58:29 +05:30
Simon Sapin
aa1eba4f5a Use skia and deps from crates.io.
Fix https://github.com/servo/skia/issues/70
2015-12-02 19:07:59 +01:00
Brandon Fairchild
341e66f66d Remove #[allow(raw_pointer_derive)] attributes
The attributes are unused.

Fixes #8699.
2015-11-27 14:32:57 -05:00
Jack Moffitt
2d35ee6d16 Fix compiler warnings 2015-09-10 09:40:06 -06:00
farodin91
f0987380dd Implement viewport functions for window #1718 2015-09-02 00:40:52 +02:00
Johann Tuffe
ec07178b6f sort all uses 2015-08-20 20:47:12 +08:00
Connor Imes
926cb903ae Some imports are used in linux only. Fixes #7088. 2015-08-08 23:03:13 -05:00
Connor Imes
b526214a3d Move net_error_list from net to net_traits. Fixes #7050. 2015-08-06 16:37:08 -05:00
zmike
a03a0cb929 implement display_handler::on_status_message for cef 2015-08-01 13:26:25 -04:00
Bruno de Oliveira Abinader
b3927d5a2d Implement Msg::Status with serialized url upon mouseover
Credits for Mike Blumenkrantz (@zmike), I just rebased against trunk and
fixed the url serialization.

Fixes #6178.
2015-07-30 16:37:54 +03:00
Martin Robinson
900337e3d1 Add memory profiling for the compositor task
Currently only the BufferMap is recorded, but a later change will also
measure the memory usage of the compositor tree.
2015-07-16 16:08:34 -07:00
bors-servo
4674afe846 Auto merge of #6525 - mrobinson:simplify-display, r=glennw
Update to latest rust-layers

The compositing context, painting context and display metadata have all
been collapsed into a single NativeDisplay class.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/6525)
<!-- Reviewable:end -->
2015-06-30 17:02:26 -06:00
Martin Robinson
0f27bd6c4b Update to latest rust-layers
The compositing context, painting context and display metadata have all
been collapsed into a single NativeDisplay class.
2015-06-30 21:58:54 -07:00
Ms2ger
c5902bac93 Remove the negate_unsigned feature gate from CEF.
There's no real reason to use it.
2015-06-27 20:01:34 +02:00
ecoal95
8cbfb3482c Use euclid from crates.io 2015-06-19 00:04:24 +02:00
Corey Farwell
5c408d2be9 rust-geom API changes
https://github.com/servo/rust-geom/pull/81
2015-06-13 12:28:21 -07:00
Mike Blumenkrantz
a1fda4af52 move cef favicon change callback to head_parsed callback to be faster 2015-06-02 22:16:29 -04:00
Mike Blumenkrantz
ffa2093012 add window method for notifying when the <head> tag has been parsed 2015-06-02 22:16:28 -04:00
Mike Blumenkrantz
612cefa02d update all cef interfaces to use borrows for string_list params
it was somewhat impossible to make this work with allocated string_lists
due to constant leakage from box allocations going out of scope, so this should
simplify it ane be more manageable in the future
2015-06-02 22:16:27 -04:00
Mike Blumenkrantz
5d99933ddc implement cef_display_handler::on_favicon_urlchange
also fixes #6166 but with more fix than last fix
2015-06-02 22:16:26 -04:00
Mike Blumenkrantz
12f20f1ecc add handling for favicon link elements
fixes #6166
2015-06-02 22:16:25 -04:00
James Graham
2b396b2485 Allow Window implementations to indicate that they don't support a clipboard.
This is important for the SERVO_HEADLESS configuration, because
creating a clipboard on linux creates an X context which then causes
reftest instability.
2015-06-02 08:57:09 +01:00
Mike Blumenkrantz
45116dca71 break out cef app wakeup code into separate pub function 2015-05-27 14:45:55 -04:00
Mike Blumenkrantz
14a6390f03 add embedding method for load_handler::on_load_error
still needs error text messages I guess
2015-05-27 14:45:52 -04:00
Mike Blumenkrantz
68fc51205f add error enum for chromium net errors, create window method for error propagation 2015-05-27 14:45:50 -04:00
Mike Blumenkrantz
3f8d8a3cc9 add back/forward/loading members to ServoCefBrowser with related browser methods 2015-05-27 14:45:49 -04:00
Mike Blumenkrantz
0d46a3b89a add navigation state data to LoadComplete messages, finish cef load state cbs 2015-05-27 14:45:48 -04:00
Mike Blumenkrantz
3481c752cd add CompositorMsg::LoadStart, implement cef_load_handler::on_loading_state_change()
only adds the loading:true callback this time...
2015-05-27 14:45:47 -04:00
Mike Blumenkrantz
cd9dab7b5b implement cef_load_handler::on_load_start() 2015-05-27 14:45:46 -04:00
Mike Blumenkrantz
a809d6b911 remove unused cef imports 2015-05-27 14:45:43 -04:00
Mike Blumenkrantz
02606fada4 implement on_address_change handler for cef port 2015-05-27 14:45:42 -04:00
Mike Blumenkrantz
caa8172560 implement cef browser title setting callback 2015-05-27 14:45:40 -04:00
Mike Blumenkrantz
af1dce5a2e add new browser process interface method for main loop integration
regular CEF requires the user to either run the cef main loop or
poll on a function to drain events. now the engine will trigger a callback
in some application thread which will notify it that there is work
to be done by the browser
2015-05-27 14:45:39 -04:00
Lars Bergstrom
442bfb716b Update various Cargo patches and deal with the fallout 2015-05-22 16:16:50 -05:00
Mike Blumenkrantz
5697d9ff2c add back browser_host::composite() method for embedding
this changes the way that applications will use servo. whereas previously
it was only necessary to call initialize() -> makecurrent, it's now necessary
to explicitly call the composite() method in order to trigger the gl rendering.

any other composite attempts (by servo) will trigger the on_paint() method,
informing the app that a frame is ready. it's then up to the app to schedule
the composite() such that the frame is rendered in a timely manner
2015-05-21 21:15:21 -04:00
Mike Blumenkrantz
789a4973f7 check method existence for hidpi_factor(), handle platforms other than macos 2015-05-21 21:15:19 -04:00
Mike Blumenkrantz
1aed319684 add pointer checks for cef method calls to avoid crashing on nonexistent methods 2015-05-21 21:15:18 -04:00
Mike Blumenkrantz
1cd850b121 add window member to servo cef browser object to fix framebuffer size method
platforms other than macos will not need/use a get_backing_rect() method since
there is no virtual pixel scaling, and this method will need to be usable
even before browsers are finished setting up, so ensure we can at least pass
initial window size back

also check method pointer availability before calling into a null function
2015-05-21 21:15:17 -04:00
Mike Blumenkrantz
e5a274b467 call XInitThreads() before creating our cef Display* object 2015-05-21 21:15:16 -04:00
Mike Blumenkrantz
09aba1f9de remove misleading FIXME(pcwalton) regarding gtk event loops in cef window 2015-05-21 21:15:15 -04:00
Mike Blumenkrantz
fb72a64833 pass width and height information through to cef paint callback 2015-05-21 21:15:15 -04:00