ddnet/src/engine/shared
bors[bot] 05ddfba954
Merge #6755
6755: Remove individual RGBA sliders from editor color picker, add shift+rightclick/leftclick to copy/paste color in editor r=Jupeyy a=Robyt3

Remove the individual RGBA sliders for editor color pickers and only show one button that opens the color picker popup instead.

Decrease size of layer and point popups that previously had color properties which need less space now.

Support shift-rightclicking color picker buttons to copy the color to the clipboard in RRGGBBAA hex format.

Support shift-leftclicking color picker buttons to paste a color from the clipboard in RGB, RGBA, RRGGBB or RRGGBBAA format with optional leading `#` or `$`.

Screenshots:
- Before:
![screenshot_2023-06-20_20-39-43](https://github.com/ddnet/ddnet/assets/23437060/4a8b230c-a66b-4e2a-9744-cb5f80f6a799)
- After:
![screenshot_2023-06-20_20-40-00](https://github.com/ddnet/ddnet/assets/23437060/517f90cf-06a5-4332-9eb8-6a87cbc91b32)
- After (color picker open):
![screenshot_2023-06-25_17-35-55](https://github.com/ddnet/ddnet/assets/23437060/30320b56-e4cb-4e93-bf7b-8cfc8d96620b)


Suggested by `@HiRavie` in https://github.com/ddnet/ddnet/pull/6743#issuecomment-1593886873, though it was easier and also looks better to me when the color picker button has exactly the same size as the other value selectors.

## Checklist

- [X] Tested the change ingame
- [X] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test (especially base/) or added coverage to integration test
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: Robert Müller <robytemueller@gmail.com>
2023-06-27 19:29:43 +00:00
..
assertion_logger.cpp Add the DDNet git hash and "is steam" to the crash file 2023-04-29 10:26:30 +02:00
assertion_logger.h Unify logging infrastructure between IConsole and dbg_msg 2022-04-29 15:21:26 +02:00
build.rs Add support for Rust code in DDNet 2022-10-19 23:46:06 +02:00
Cargo.toml Add support for Rust code in DDNet 2022-10-19 23:46:06 +02:00
compression.cpp Consistently use static const instead of const static 2022-11-29 23:32:32 +01:00
compression.h Add size checks to CVariableInt::Pack and ::Unpack 2022-03-05 20:49:55 +01:00
config.cpp Simplify io_write_newline error handling 2023-02-18 14:13:55 +01:00
config.h Minimal changes to default to Vulkan 2022-12-13 19:37:03 +01:00
config.rs Add support for Rust code in DDNet 2022-10-19 23:46:06 +02:00
config_variables.h Split emoticon sending into nearby and global players 2023-06-11 13:31:50 +02:00
console.cpp Add color_parse function to parse strings as colors 2023-06-20 23:22:33 +02:00
console.h Quit client when existing config file cannot be loaded 2023-05-10 21:04:02 +02:00
csv.cpp Add a simple CSV writer for Python's "excel" csv dialect 2020-06-23 09:11:59 +02:00
csv.h Fix some variable name's style 2020-11-08 17:15:48 +01:00
datafile.cpp Use separate thread to finish saving maps, add saving indicator 2023-06-26 21:58:04 +02:00
datafile.h Use separate thread to finish saving maps, add saving indicator 2023-06-26 21:58:04 +02:00
demo.cpp Use sizeof(int32_t) instead of 4 2023-02-11 13:59:08 +01:00
demo.h Prevent temporary demo file from being deleted multiple times 2022-12-30 14:20:42 +01:00
econ.cpp Quit when configured bindaddr cannot be resolved 2023-03-23 21:34:07 +01:00
econ.h Organize engine-shared includes 2022-06-17 17:39:24 +02:00
engine.cpp Fix logging (fixes #6611) 2023-05-18 21:54:30 +02:00
fifo.cpp Add templated str_append function for arrays with fixed size 2023-06-14 00:04:01 +02:00
fifo.h Implement FIFO on Windows using Named Pipes 2023-01-21 11:13:02 +01:00
filecollection.cpp Use IO_MAX_PATH_LENGTH in CFileCollection 2023-06-25 10:49:57 +02:00
filecollection.h Replace all usages of C standard headers with C++ headers 2023-03-01 19:26:51 +01:00
global_uuid_manager.cpp Move teehistorian UUIDs into engine 2018-01-11 16:01:13 +01:00
http.cpp Check if HTTP request task is aborted in completion callback 2023-03-25 12:43:19 +01:00
http.h Stop server if started with old curl and incompatible sv_register 2022-09-22 00:09:02 +02:00
huffman.cpp Remove redundant variable assignments 2022-11-29 23:32:26 +01:00
huffman.h Mark CHuffman::Compress and ::Decompress as const 2022-04-02 13:35:24 +02:00
jobs.cpp Add CLockScope 2022-06-03 12:21:23 +02:00
jobs.h Organize engine-shared includes 2022-06-17 17:39:24 +02:00
json.cpp Run clang-format 2020-09-26 21:50:15 +02:00
json.h Run clang-format 2020-09-26 21:50:15 +02:00
kernel.cpp Let CKernel clean-up. Use unused CSound::Shutdown 2022-09-16 16:50:19 +02:00
lib.rs Add support for Rust code in DDNet 2022-10-19 23:46:06 +02:00
linereader.cpp Add modernize-use-bool-literals 2022-02-15 00:12:52 +01:00
linereader.h Fix announcement feature, don't depend on buffer staying consistent 2023-01-13 16:22:22 +01:00
localization.h Add Localizable hint 2022-12-13 17:53:32 +01:00
map.cpp Add missing CMap::NumData delegate function 2023-05-15 20:47:59 +02:00
map.h Add default parameter values to CMap::GetItem 2023-05-15 20:48:01 +02:00
masterserver.cpp Add HTTP masterserver registering and HTTP masterserver 2022-05-20 08:58:32 +02:00
masterserver.h Add HTTP masterserver registering and HTTP masterserver 2022-05-20 08:58:32 +02:00
memheap.cpp Organize base includes 2022-06-17 17:39:25 +02:00
memheap.h Add CHeap::StoreString method 2022-05-06 23:21:26 +02:00
netban.cpp Reduce duplicate code by extracting CNetBan::CBanPool::InsertUsed 2022-12-06 20:18:08 +01:00
netban.h Reduce duplicate code by extracting CNetBan::CBanPool::InsertUsed 2022-12-06 20:18:08 +01:00
network.cpp Remove check for pResponseToken, which isn't used on this code path 2022-12-06 20:37:59 +01:00
network.h Fix NET_MAX_CHUNKHEADERSIZE 5 -> 3 2023-04-23 11:51:34 +02:00
network_client.cpp Allow multiple connect addresses 2022-07-10 16:57:10 +02:00
network_conn.cpp Mark parameters as const when possible 2022-11-29 23:32:31 +01:00
network_console.cpp Port some code to str_copy() template 2022-07-09 19:40:58 +03:00
network_console_conn.cpp Port some code to str_copy() template 2022-07-09 19:40:58 +03:00
network_server.cpp Use sizeof(int32_t) instead of 4 2023-02-11 13:59:08 +01:00
network_stun.cpp Only compare with old STUN server address if we have any 2022-07-10 16:53:15 +02:00
packer.cpp Fix off-by-one error when adding raw data to buffer 2023-05-03 19:13:39 +02:00
packer.h Add default parameter for CPacker::AddString 2023-05-03 18:17:27 +02:00
protocol.h Add net netobjs for projectile and pickup, extend ddnetlaser, remove EntityEx server-side 2023-05-04 23:43:05 +02:00
protocol7.h Add 0.7 system message constants 2023-02-14 11:40:55 +01:00
protocol_ex.cpp Organize engine-shared includes 2022-06-17 17:39:24 +02:00
protocol_ex.h Organize engine-shared includes 2022-06-17 17:39:24 +02:00
protocol_ex_msgs.h Fix ddnet.org change in UUIDs 2023-01-12 15:38:17 +01:00
ringbuffer.cpp Add modernize-use-bool-literals 2022-02-15 00:12:52 +01:00
ringbuffer.h Fix some variable name's style 2020-11-08 17:15:48 +01:00
rust_version.rs Add support for Rust code in DDNet 2022-10-19 23:46:06 +02:00
serverinfo.cpp fix conflicts 2023-05-14 11:22:06 +02:00
serverinfo.h fix conflicts 2023-05-14 11:22:06 +02:00
snapshot.cpp Fix undefined behavior in CSnapshotDelta::DiffItem 2023-05-27 20:57:05 +02:00
snapshot.h Replace all usages of C standard headers with C++ headers 2023-03-01 19:26:51 +01:00
storage.cpp Autosave copy of current editor map periodically to auto folder 2023-06-26 21:58:04 +02:00
stun.cpp Use STUN to determine UDP connectivity and show diagnostics 2022-05-18 09:21:31 +02:00
stun.h Add bare-bones STUN protocol support 2022-05-18 09:20:54 +02:00
teehistorian_ex.cpp Run clang-format 2020-09-26 21:50:15 +02:00
teehistorian_ex.h Run clang-format 2020-09-26 21:50:15 +02:00
teehistorian_ex_chunks.h Record player switch in teehistorian 2022-05-21 21:37:17 +02:00
uuid_manager.cpp Add comments explaining UUID generation 2023-02-20 20:05:26 +01:00
uuid_manager.h Use std::vector<CName> instead of array, adjust variable name 2022-05-27 16:31:18 +02:00
video.cpp Organize engine-shared includes 2022-05-29 20:02:22 +02:00
video.h Use existing typedef instead of duplicating arguments 2022-06-17 17:39:26 +02:00
websockets.cpp Use mem_copy instead of memcpy for websockets 2023-03-09 13:16:49 +01:00
websockets.h Replace all usages of C standard headers with C++ headers 2023-03-01 19:26:51 +01:00