Summary:
The code to initialize outputs has duplicate stanzas for updating the
data members of the output structure. This set of refactoring steps
shuffles things around to eliminate the redundant code. I think this
also makes the code easier to follow too.
This also breaks out a new internal routine for looking up outputs by
id. I suspect this will have general usefulness later.
Reviewers: devilhorns, cedric, zmike
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2077
Summary: Add doxygen comments for public API members
Reviewers: zmike, cedric, devilhorns
Reviewed By: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2067
Summary:
Many of the functions in the compositor do some preliminary checks, to
ensure objects are valid and the right type. Most of the checks follow
a consistent pattern, for example:
if (!(ec = data)) return;
if (e_object_is_del(E_OBJECT(ec))) return;
if (ec->iconic) return;
This style makes it pretty straightforward to review the pre-conditions
of the function.
The one exception is the check to see if an object is a wayland pixmap;
this is implemented as a C macro.
E_COMP_WL_PIXMAP_CHECK;
The name of the macro is descriptive enough, but it conceals what is
actually being checked. I think that it is clearer and fits better with
the style of the rest of the pre-condition checks for this check to just
be shown as regular C code:
if (e_pixmap_type_get(ec->pixmap) != E_PIXMAP_TYPE_WL) return;
Reviewers: zmike, cedric, devilhorns
Reviewed By: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2066
Summary:
All other E_NEW calls in this file check the return value, except this
one place. In this function, other calls are being checked for NULL and
handled so this one should as well. The other handlers in this function
follow the style of issuing an error message, freeing objects, and
returning false; we don't need to free anything so just do the error
message and return.
Reviewers: zmike, cedric, devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2065
Summary:
Clamping to Y makes pop ups get shifted up if a window is
near the top of the screen.
Reviewers: devilhorns, zmike
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2060
Summary:
These two functions are nearly identical so move much of the common code
into a helper function.
Reviewers: cedric, devilhorns, zmike
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2053
Summary:
We should be building Enlightenement with "--enable-wayland-only"
even if xcb, ecore-x... are not present. The Evas wayland-shm
engine will then be a prerequisite, though.
E_Alert being too much X11-oriented, let us disable it completely
before it is ported.
Also, do not require the X11 rendering engines at runtime.
Reviewers: stefan, devilhorns
Reviewed By: devilhorns
Subscribers: stefan_schmidt, stefan
Projects: #enlightenment-git
Differential Revision: https://phab.enlightenment.org/D1986
Summary:
cosmetic: Cleanup whitespace for wayland compositor
There is excess trailing whitespace in several of the files for the
wayland implementation. These patches attempt to apply the spacing
rules for Enlightenment as documented at:
https://phab.enlightenment.org/w/coding_convention/
The whitespace rules are applied using the following emacs tabbing
settings:
(defun start-efl-c-mode ()
"C mode with adjusted defaults for use with Enlightenment
development."
(interactive)
(c-mode)
(c-set-style "gnu")
(setq tab-width 8)
(setq indent-tabs-mode nil)
(setq c-basic-offset 3)
(setq defun-block-intro 3)
(setq statement-block-intro 3)
(setq case-label 1)
(setq statement-case-intro 3)
)
This patchset also eliminates all tabs in favor of whitespace, as per
the coding style rules.
Reviewers: zmike, cedric, devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2048
Summary:
We should keep a list of resources per output to propagate wl_output
changes to each client that bound an output.
The output list now contains all outputs, not just bound ones.
Reviewers: devilhorns, zmike
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2047
Summary:
wayland: Check wl_array_add return for OOM condition
cosmetic: Make error return check syntax consistent with rest of code
wayland: Reuse use_adj to track child-forced adjust
wayland: Refactor to collapse if chain
wayland: Refactor _e_comp_wl_client_priority_adjust to collapse if chain
+ This uses early returns to unwrap a couple if clauses to make the code a bit less nesty.
wayland: Refactor if statements for consistency with rest of file
Reviewers: cedric, zmike, devilhorns
Subscribers: devilhorns, cedric
Differential Revision: https://phab.enlightenment.org/D2034
This fixes the crash and creates outputs based on e_randr
configuration (when in wayland-client mode).
Signed-off-by: Chris Michael <cp.michael@samsung.com>
this speed sup dir listing in efm drastically. first the e fm back end
uses an io thread that just spools through everything fast and sends
it over the mainloop to then send by ipc to e.
and on the e side we no longer use the heavy file internal magic using
api calls that wander all over a file for magic numbers - this is
insanely slow and brings listing to a crawl.
this came in a patch that I take full responsibility for not adequately reviewing at the time.
the names are confusing and counterintuitive, and it does not properly include the client namespace.
Summary: Building without ptrace (on OSes which do not support it, like OpenBSD) did not work, because the fallback code had small typos.
Reviewers: devilhorns
Projects: #enlightenment-git
Differential Revision: https://phab.enlightenment.org/D1990
Summary:
This fixes T1828.
The theme also would have to support this!
Reviewers: zmike
Subscribers: myoungwoon, cedric
Maniphest Tasks: T1828
Differential Revision: https://phab.enlightenment.org/D1798
We don't have e_randr2 calls for wayland yet, so ifdef those out if we
are building for wayland only
Signed-off-by: Chris Michael <cp.michael@samsung.com>
this adds 2 actions that only suspend a laptop (or hibernate) if there
are no external screens enabled. if there is no lid screen eg like a
desktop, then it will still go on as usual.
Summary:
Update the error message shown if a theme file is invalid. This isn't E17 any more. rEec1cd25cfe666665b9e5641c91d3ad1fd2f9f11c
{F13161 size="full"}
Reviewers: zmike, raster
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1959
Wayland cursor set events should be ignored if the client sending them
doesn't own the surface the pointer is currently in.
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
this makes highest priority screen the lowest (0) zone. this also
handles missing screesn that you are relative "of". missing clones are
not working atm. also zone reconfigure moves windows now too
many clients still have not had a first commit prior to running new_client placement,
so this will force a second run of that algo to prevent placing as though a client's
size = 1x1
for wahetever reason i dont get warnings from gcc:
-Wno-shadow -Wno-unused-but-set-parameter -Wno-clobbered -W -Wall -Wextra
are the warning flags i get and i simplt dont get a tonne like using
uninitialized var. don't know why.
this fixes some issues in the new randr2 code that made it not work
right with plug/unplug and lid close/open. now it does work right and
plugging/unplugging displays is seamless (if your driver does not give
plug/unplug events bind a key to update screen config acvtion and e
will figure it out when you hit the key).
<zmike> super funny idea: for client cursors, what if we just implement them as an override client with no animations and then hide the canvas cursor while the client is visible?
this started as a joke and it worked mostly fine so I improved it and now it's shipping and whatdoidowithallthesebugs.jpg
the problem is something changes window gravity... what i don't know,
but hey - just forcibly move window to 0,0 which is where we expect it
anyway when resizing.
@fix
when your laptop lid opens/closes even if we dont get a randr event
with a disconnect, the screen as logically been unplugged (you can't
see it anymore) so we should treat it as if the screen is not
connected. this fixes that.
the previous patch(es) had a number of issues which made them unsuitable for general use:
* only checking "/usr" and "/usr/local" paths, despite this only being accurate if e was installed into /usr or /usr/local
* only checking if the paths were at the beginning of the string, when it's possible that they could be anywhere
* failure to also check XDG_CONFIG_DIRS
* improper formatting: this is a bit of a nitpick, but there are no correct instances of 'strcmp(a, b) == 0' in the e codebase.
This commit @fix a duplicated entry in XDG_DATA_DIRS which is also
added prematurely, if eina_prefix_get is already /usr (most of the
times) we dont want to add it here
(cherry picked from commit f42f5f1cfe)
Signed-off-by: Deon Thomas <PrinceAMD.Elive@gmail.com>
the dialog for now is simple and lets you just raw edit the properties
per screen in a dialog. nothing fancy. not user firendly. but it works.
the randr core has been totally rewritten and tested against a range
of drivers and setups before even getting a commit. it works solidly
and configures screens reliably now. drivers tested:
nvidia
intel
radeon
some drivers still are unreliable in terms of delivering plug/unplug
events for outputs (both intel and radeon are flakey - nvidia is solid
and reliable). so to fix this there is now a screen redo action you
can bind to a hotkey or something and have e re-evaluate current
screen setup and apply ny pending config if needed.
also to make reconfiguring prettier the screen is faded to black
first, then configured, then faded back in. some drivers work
flawlessly with this, others still flicker some garbage.
i admit - i haven't tested nouveau, but my general take on this is the
randr code is now in far better shape than where it was (minus pretty
and easy dialog). the dialog can be done next, but i'd like to get the
core in now for more testing.
@fix
Summary:
Resolved TODO to release list of touch resources in e_comp_wl_input_shutdown
Signed-off-by: kabeer khan <kabeer.khan@samsung.com>
Reviewers: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1884
first place anyway. shoudl replace the entire dialgo one at a time by
an elm version not try and stuff elm widgets into where e widgets used
to be. this doesnt improve e's config dialogs, just makes them buggy
as all hell in the name of a move to elm.
Revert "e_widget_button -> elm_button conversion"
This reverts commit b1c976d80d.
Revert "update widget size hints when setting a resize object"
This reverts commit fdab0218b2.
Revert "remove no-longer-necessary size hinting in list widgets"
This reverts commit 21479f5019.
Revert "e_widget_textblock -> elm_entry conversion"
This reverts commit 8fe2f00f75.
Revert "e frame -> elm_frame conversion"
This reverts commit e9da6a02fc.
Revert "remove unnecessary size hinting"
This reverts commit b596623efd.
Revert "e_label -> elm_label conversion"
This reverts commit 049b318679.
Revert "set evas size hint min in widget min size"
This reverts commit 2f09aa2fda.
Revert "e_table -> elm_table conversion"
This reverts commit 6434012982.
Revert "remove unused vars"
This reverts commit b19e706b23.
This reverts commit 1ec2a4e91c.
this may have fixed wayland window centering, but only because it effectively turns the function into a no-op instead of actually centering the window
@fix
this should fix T1988. after some looking here is what i think is
happening. he is asking the system (sysvinit or systemd) to
halt/reboot, but these end up killing the e process before it can save
its config that is lurking around still in ram as opposed to on disk,
so puttting in a config flush before beginning such a system action
will ensure everything is on disk.
Since we call this function before it's actually defined in the
source, we'll just add a small function prototype at the top
Signed-off-by: Chris Michael <cp.michael@samsung.com>
borderless
This fixes the issue of elementary windows having 2 borders, however
it does expose a new issue where those same internal elm windows now
have a black shadow border around them.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
This fixes an issue where internal elementary dialogs would end up
creating 2 pixmaps and 2 clients for each window. This happened due to
the pixmap id not matching the elm window id.
This patch also handles reparenting internal elm windows if needed.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: add the condition check code if the pressed key is not in range of menu items
Test Plan:
(1) Left-click on the desktop to bring up the menu.
(2) Press down the number key to activate the menu item.
(3) When you press down the number key that is not in range, you will see the segmentation error.
below is the crash log which I encoutered.
-------------------------------------------------------------------
Program received signal SIGSEGV, Segmentation fault.
_e_menu_item_activate_nth (n=n@entry=5) at src/bin/e_menu.c:2318
2318 _e_menu_item_ensure_onscreen(mi);
Reviewers: zmike, gwanglim, raster
Reviewed By: raster
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1845
there is only one E_Comp which can now be accessed by the e_comp global.
if you're editing a file with some uses of these deprecated functions, replace their usages with appropriate references to this variable
pass -Wno-deprecated-declarations to ignore these warnings during build
Summary:
Compositor need to change the compositing mode to offscreen or render state depend on session activation state.
this patch is for it.
Test Plan:
(1) Run enlightenment on X.
(2) Change another VT.
(3) Run enlightenment on wayland and drm.
(4) Change the VT to enlightenment which is ran (1).
enlightenment on wayland will not render during session deactivation state.
Reviewers: zmike, devilhorns
Reviewed By: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1816
this was removed without warning or explanation in r82118:
e: Change notification module to use internal notification API
Patch by: José Roberto de Souza <zehortigoza@profusion.mobi>
currently broken by T1954 for lines longer than 36 characters
This reverts commit 9157ca8ca7.
this also makes all dialogs that have content in a toolbar that goes
off window at min size resizable - this is actually what you wanted ..
bgut this previous "all dialogs are resizable" thing was uber-lazy.
Conflicts:
src/modules/bluez4/e_mod_main.c
src/modules/conf_bindings/e_int_config_signalbindings.c
src/modules/conf_theme/e_int_config_theme.c
src/modules/mixer/conf_gadget.c
src/modules/shot/e_mod_main.c
init of e_screensaver sets up an event handler for the
powersave_update event (which would be 0 unless powersave is init
first).
Thanks to dt9 for the report ! ;)
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary:
Correct the way to parse syntax in key bindings for launching application according to syntax guide
and pop an error dialog when a space is detected while activating the action.
Example:
Guide is given like "exe:xterm" with "No whitespace" between param's name and contents.
However, existing way to parse syntax should require "ONE whitespace" between name and contents.
This modification will parse syntax correctly.
@fix
Reviewers: seoz, zmike, Hermet
Subscribers: raster, cippp, cedric
Differential Revision: https://phab.enlightenment.org/D1699
If we do E_Randr_Output *out2 = _e_randr_output_find(output->xid), then
output should be equal to out2, else we have several output variables per
output xid which should be fixed correctly.
This does not change any behaviour, just moves code:
1. We only try to locate a crtc for an output in _e_randr_output_active_set
And we only do this when we set active.
2. We only search for a crtc in _e_randr_output_crtc_find
This includes looping known crtcs without querying X if it matches.
Please don't revert, but help cleaning. As the current code does not
work for me...
This reverts commit 4aef218d28.
Revert "randr: remember crtcid for fast lookup on reconnect"
This reverts commit 55b4ad41d1.
Revert "randr: further cleanup"
This reverts commit 3e02824663.
these make nvidia randr resolution changing work again. sorry seb.
even though cleanups might be nice... this code is FIDDLY and every
driver seems to work differently, so take it easy and be very careful
- make no assumptions. i know it works on my intel desktop and nvidia
deskop atm. once i get a vga cable i'll fix up intel laptop with
external display that has problems. i can try radeon too later. but
right now - this stuff needs to work. being clean is far less
important than working. :)
When an output is set inactive, it is disconnected from a crtc. Now we
remember the id of the last crtc it was connected to, so we get a faster
lookup on reconnect.
the dp checks were looking for edp stuff. but due to naming they appeard as
eDP or maybe edp or EDP - thus were simplified to dp. put more explicit
checks there.
Primarly two things removed:
1. crtc->outputs should only contain outputs which should be enabled
So looping them twice in e_randr_apply is definitly wrong.
2. _e_randr_crtc_find should find a crtc for an output
So looping our crtcs again in _active_set is definitly wrong. If
_e_randr_crtc_find does not find us a crtc, it should be fixed there.
i've spent a while testing randr on my nvidia box and drviers. it now
works - i can turn screens on and off. i couldn't before. e_randr was
trying to be too smart for its own good. it wasnt matching up outputs
to crtcs, was thinking outputs active when they were not, etc. etc.
etc. - reality is e_randr could do witha lot of simplification, but
at this stage i'm just going to hammer it into shape to work across as
many drivers and setups as i can test against.
We should not set the title to "E" in the trap function of show.
If we do this we will override the icccm title and the netwm name, this
mean e_comp_x will set E as title of the window if the call to
elm_win_title_set was BEFORE the window was shown.
Now the name which was set before will be inserted.
Summary:
Otherwise the mouse up event is emitted to the evas but the evas does
not work with it, because it does not know the window it is from. This
leads to a evas_event_down_count_get bigger than 1 which leads to a
missing mouse_out event. With this missing mouse_out event _post_up_handle
in evas_event.c is not called anymore, this means all the click events
are getting emitted to the object which was last clicked.
This fixes T1894.
Test Plan: Drag and Drop a icon somewhere and click somewhere after that, the evas will not get stuck anymore
Reviewers: raster
Subscribers: cedric, abyomi0, zmike, raster
Maniphest Tasks: T1894
Differential Revision: https://phab.enlightenment.org/D1771
this hasn't been updated in over 1.5 years and has caused me to waste time repeatedly fixing build-related issues. in addition, it uses symbols which are no longer even available in efl.
if nobody updates/maintains this, it will be removed for e20 release
src/modules/access/e_mod_main.c: In function '_cover_new':
src/modules/access/e_mod_main.c:765:4: warning: implicit declaration of function 'ecore_x_input_multi_select' [-Wimplicit-function-declaration]
according to the shape extension protocol, the number of rectangles returned should be checked to determine a client's shape. if 0 is returned, the client has no shape, meaning that it either should not be drawn or should have no input region. this improves behavior with various client window types such as tooltips
ref T1820
On some systemd SIGQUIT causes the logger to save a coredump.
Quiting bc here does not need save a backtrace here, the termination is
not a crash its a "closing" of the program.
The backlight module has an action to show the value of the backlight brightness
by showing the gadget's popup. Added a parameter to this action to adjust the
brightness at the same time.
Summary: This moves the additional actions to the top of the menu and the seperator right underneath.
Reviewers: zmike
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1694
Summary: Seems one of the Daniels did not check their compiler output
;) _e_ptrace_attach function should return an integer value...
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary:
The intel_pstate scaling driver exposes the `scaling_cur_freq` since
kernel 3.17 [*], it would be fine that the min and max frequencies
are known even without the `scaling_available_frequencie`.
This commit teaches to use the cpuinfo_{min,max}_freq as fallback in
case the `scaling_available_frequencies` is not available within
intel pstate.
[*] https://lkml.org/lkml/2014/11/11/1060
Signed-off-by: Takeshi Banse <takebi@laafc.net>
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1686
so e was storing randr config using XIDs to match outputs etc. this is
all kinds of wrong. XIDs are NOT STATIC. they change from xserver to
xserver and from run to run. they MAY be the same. they may not. so
this was just broken.
use output name + edid as a big "string" (name.edid) as a way ofr
identifying config for a specific combination of output plus monitor
and to find/identify the corrent output+monitor to apply it to (of
course missing edid gets replaced with ??? and missing output name is
??? too - i have never seen a missing output name so you get this at
least).
so this FIXES "restore" of screen mode on login for starters. this
does nothing to "fix" the screen setup dialog in any way. there are
separate issues there.
this also breaks e_randr config compat so i bumped epoch so your old
config is rejected. i don't see a sensible way of porting the config
forward.
Summary:
Changed the key to orig_path, cause this is used to decided if something
is a duplicated entry in e_orders or not.
Reviewers: zmike
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1684
Summary:
This fixes the case when par is NULL, this means we should insert a
parent node between the 2 nodes and root. (T1790)
Example:
Each Number is a Window,
12
Focus on 2
Press Win+Up should end up in this:
2
1
This patch also makes the bahavior for 2 windows more
consistent
12
Focus on 2
Pressing Win+Right,
21
It Will just swap the nodes,
This is the same behavior then in higher levels.
Reviewers: tasn
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1643