Commit Graph

16207 Commits

Author SHA1 Message Date
Christopher Michael a9f1783e5f When calculating virtual size, also account for 'possible' outputs.
When we are creating the monitors, account for 'possible' outputs also.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84198
2013-02-19 10:59:06 +00:00
Christopher Michael 1d10a382b6 Actually, allow move/resize/rotate for disabled monitors so things can
be adjusted (NB: Will not actually mattery on Apply anyway).

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84197
2013-02-19 10:59:03 +00:00
Christopher Michael c5254ce545 Set current size and position text when we set current values.
Add function for setting current geometry.
If a monitor is disabled, do not allow rotate, resize, move events.
Fix resize start/stop functions to use current geometry.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84196
2013-02-19 10:59:00 +00:00
Christopher Michael c0d5cbad61 Add function prototype for setting current geometry.
Rename function prototype for grid virtual size set.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84195
2013-02-19 10:58:57 +00:00
Christopher Michael f48772482c Fix move_stop to use current geometry.
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84194
2013-02-19 10:58:54 +00:00
Christopher Michael 2819733656 Handle setting monitor to enabled/disabled based on crtc mode.
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84193
2013-02-19 10:58:51 +00:00
Christopher Michael 87ef25f21b When calculating virtual size, we only need to fetch
"screen_current_size_get" if both vw & vh are 0.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84192
2013-02-19 10:58:48 +00:00
Christopher Michael 2acdd3f3e2 Add 'current' field values so we can use these durring apply for
comparison to old values.
Fix move, resize, rotate code to use "current" values.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84191
2013-02-19 10:58:45 +00:00
Christopher Michael aee6393591 Add code to handle manual monitor movement.
Fix up coordinate functions to not need doubles.
Update monitor position text when moving.
Fix up rotation code to allow rotating when mouse is outside the frame
(thank you Daniel) ;)

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84190
2013-02-19 10:58:42 +00:00
Christopher Michael aa74a39589 Fix grid offset
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84189
2013-02-19 10:58:39 +00:00
Christopher Michael b33401f645 Add in refresh_rate code for filling refresh rate list and listening
for changes.
Break map_apply function into frame_map_apply and thumb_map_apply for
rotating just the wallpaper.
Fix resize code to work with a rotated monitor.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84188
2013-02-19 10:58:36 +00:00
Christopher Michael 39bc25be03 Use ecore_x_randr_crtc_info_free function to free returned crtc_info.
When comparing refresh rates for mode searches, cast to int.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84187
2013-02-19 10:58:33 +00:00
Christopher Michael 2e0f4e7a27 Reduce variable usage
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84186
2013-02-19 10:58:31 +00:00
Christopher Michael e02c9fc7aa Fix comment.
Remove orientation comparison.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84185
2013-02-19 10:58:28 +00:00
Christopher Michael af59660d3f Add ROTATE_FUZZ amount.
Add inline function to get orientation based on rotation amount.
Add function to apply an evas_map for rotation.
If we are rotating, we don't need to set livethumb size.
When we start rotating, set initial rotation amount to 0.
When rotation stops, update the map and monitor position where needed.
Apply map during rotation.

NB: This commit also adds a debugging red rectangle behind the
monitor. This will be removed when debugging is complete

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84184
2013-02-19 10:58:25 +00:00
Christopher Michael c2b2be5be7 Add current rotation to smart_data structure.
Fill in current rotation on crtc set.
Update current rotation when we get a rotation event.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84183
2013-02-19 10:58:22 +00:00
Christopher Michael 35855135a1 Add inline function to return the degree of rotation based on
orientation.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84182
2013-02-19 10:58:19 +00:00
Christopher Michael 87daec404d Remove Big Fat Fixme warning as it's fixed now :)
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84181
2013-02-19 10:58:16 +00:00
Christopher Michael ed84b96078 Add code to check EFL version.
If we are using a newer version, then we can use the new
ecore_x_randr_crtc_info_get() function which will save us a lot of X
round-trips.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84180
2013-02-19 10:58:13 +00:00
Christopher Michael 93ad1faf50 Add current mode and refresh rate to crtc field.
Add function prototype for getting a mode refresh rate.
Add Big Fat FIXME for crtc_set function.
Get the crtc current mode & refresh rate when crtc is set.
Simplify monitor_mode_find function.
Add function for getting a mode refresh rate.
Start on rotation event code.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84179
2013-02-19 10:58:10 +00:00
Christopher Michael 1ec01f9d65 Add function to get the amount of rotation from a mouse event.
Simplify mouse movement check in resize_event and add some better
comments.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84178
2013-02-19 10:58:06 +00:00
Christopher Michael 3526741c82 Turn 'crtc' field into a structure (mainly for making code easier to
read/maintain).

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84177
2013-02-19 10:58:04 +00:00
Christopher Michael 5b47415f14 Add code to check if rotations for a given crtc are possible, and
disable the rotation in edje if not.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84176
2013-02-19 10:58:01 +00:00
Christopher Michael 9edea3c781 Only get edid (an expensive process) if getting the output name
previously has failed.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84175
2013-02-19 10:57:57 +00:00
Christopher Michael 7abc8a7aca Add flag for rotating to structure.
Add & delete callbacks for rotation start & stop.
Add functions for rotate start & stop.
Add start of rotate event code.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84174
2013-02-19 10:57:55 +00:00
Christopher Michael 2edc7cfeaf Add some comments.
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84173
2013-02-19 10:57:52 +00:00
Christopher Michael 480170d4ce Remove all code which tried to maintain aspect ratio of the frame
(resize snapping to mode dimensions will handle this anyway).

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84172
2013-02-19 10:57:50 +00:00
Christopher Michael 1f63b0f062 Remove dead comments about layout object.
Add grid object to structure.
Add callbacks to handle when grid gets moved or resized so we can
update the monitor's copy of the grid geometry.
Update calls to monitor_grid_set to pass in geometry now.
Add monitor_virtual_size_set call.
Add code to deal with grid getting moved & resized.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84171
2013-02-19 10:57:47 +00:00
Christopher Michael bda3e4bcdc Change structure to store grid geometry.
Change grid_set function to accept grid geometry.
Add monitor_virtual_size_set function.
Only update livethumb preview size if we are not manually resizing.
Don't need to set the resolution text during smart_resize.
Add functions to convert coordinates to/from virtual to canvas.
Add function to find the closest randr mode to a given size.
Add function to handle user manual resizing.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84170
2013-02-19 10:57:44 +00:00
Christopher Michael 903787a594 Change monitor_grid_set function to also accept the grid geometry
(used for virtual-->canvas coordinate functions).

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84169
2013-02-19 10:57:41 +00:00
Christopher Michael fd0889b31a Add missing LOGFN's where needed.
Add mouse_move callback on frame.
Delete mouse_move callback when we delete the frame.
Add code in frame moouse_move function to call appropriate event based
on current action.
Start of actual resize event code.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84168
2013-02-19 10:57:38 +00:00
Christopher Michael f4ae6fac22 Add flag to structure for resizing.
Add start of resize coordinates to structure.
If we are manually resizing the object, update the text.
When resize starts, record the current mouse position and size.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84167
2013-02-19 10:57:35 +00:00
Christopher Michael fd11b69ad5 Add edje callbacks to frame for resize_start & resize_stop.
Add code to delete edje callbacks from frame when object is deleted.
Add start of code for resize_start & resize_stop frame events.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84166
2013-02-19 10:57:32 +00:00
Christopher Michael 22f25b4c1d Fix variable type of "name" to be char (not const char).
Add code to set mouse pointer on frame events (resize, rotate, etc).

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84165
2013-02-19 10:57:29 +00:00
Christopher Michael 825ccb9256 Cleanup some memory returned from ecore_x_randr when we are done with
it.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84164
2013-02-19 10:57:26 +00:00
Christopher Michael b5f6ae6d0d Fix comment.
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84163
2013-02-19 10:57:24 +00:00
Christopher Michael f5fc65f945 Add function to push & pop e_pointers.
Add code to set pointer indication when mouse moves inside the
thumbnail.
Add code to set pointer indication when mouse is down on the thumbnail.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84162
2013-02-19 10:57:21 +00:00
Christopher Michael 9354ef67ae Set aspect width & height on the same line
(pedantic commit just to remove 2 extra lines).

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84161
2013-02-19 10:57:18 +00:00
Christopher Michael 353df08f07 Also pass in crtc geometry to the monitor when we set crtc (because we
have previously fetched this geometry anyway).

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84160
2013-02-19 10:57:14 +00:00
Christopher Michael 457c302e92 Modifiy crtc_set function to also take the current crtc coordinates
(this saves us a round-trip function call to ecore_x_randr as we
already have the coordinates from the randr widget).

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84159
2013-02-19 10:57:12 +00:00
Christopher Michael 54a0fa16ae When we set the crtc of the monitor, we can update position and
resolution text.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84158
2013-02-19 10:57:09 +00:00
Christopher Michael 58b68ab98b Add private functions for setting monitor position and resolution text.
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84157
2013-02-19 10:57:06 +00:00
Christopher Michael 597d95bdb6 Add code to set the monitor name.
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84156
2013-02-19 10:57:04 +00:00
Christopher Michael ad6d6914bc Pack the monitor into the grid first, then do setup.
Add function call to setup initial background preview.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84155
2013-02-19 10:57:01 +00:00
Christopher Michael b12e6c9c12 Add note about screen_reset.
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84154
2013-02-19 10:56:58 +00:00
Christopher Michael 8d47671e6e Add code to handle setting of background preview on initial show.
Add code to handle setting of background preview when user changes the
bg.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84153
2013-02-19 10:56:54 +00:00
Christopher Michael 6ca0528ef0 Remove function call to monitor_virtual_size_set.
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84152
2013-02-19 10:56:51 +00:00
Christopher Michael 055ccc581e Remove virtual_size_set code (turns out, it's not needed).
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84151
2013-02-19 10:56:48 +00:00
Christopher Michael 70380b6125 Add base & grid object to randr widget.
Use ecore_x_randr functions to get crtcs & outputs (Fixes problem of
running Screen Setup dialog in Xephyr)
Add code for min_size_get function.
Remove code which used e_layout widget.
Add code to create new randr widget based on evas_object_grid.

Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84150
2013-02-19 10:56:45 +00:00
Christopher Michael efbdf8c9d0 Add function prototype for min_size_get.
Signed-off-by: Christopher Michael <cp.michael@samsung.com>

SVN revision: 84149
2013-02-19 10:56:43 +00:00