Files
test/intern/ghost/intern/GHOST_PathUtils.hh
Campbell Barton 82c753a940 GHOST/Wayland: drag & drop cleanup, minor changes
- Don't generate a drop event when the drop data failed to read.
- Remove redundant drop-buffer duplication.
2024-02-16 14:26:58 +11:00

27 lines
773 B
C++

/* SPDX-FileCopyrightText: 2010 Blender Authors
*
* SPDX-License-Identifier: GPL-2.0-or-later */
/** \file
* \ingroup GHOST
*/
#pragma once
/**
* Decode URL (i.e. converts `file:///a%20b/test` to `file:///a b/test`)
*
* \param buf_dst: Buffer for decoded URL.
* \param buf_dst_maxlen: Size of output buffer.
* \param buf_src: Input encoded buffer to be decoded.
* \param buf_src_len: The length of `buf_src` to use.
*/
void GHOST_URL_decode(char *buf_dst, int buf_dst_size, const char *buf_src, int buf_src_len);
/**
* A version of #GHOST_URL_decode that allocates the string & returns it.
*
* \param buf_src: Input encoded buffer to be decoded.
* \return The decoded output buffer.
*/
char *GHOST_URL_decode_alloc(const char *buf_src, int buf_src_len);