Suppose we have some bounded Borel set $B\subset {\mathbb R}^n$. Let a function $f:B\to \mathbb R$ be uniformly continuous on B in the sense that $$w(r):=\sup_{x,y\in B\ :\ |x-y|\le r}|f(x)-f(y)|<\infty$$ for all $r>0$, and $w(r)\to 0$ as $r\to +0$. Is it always possible to extend the function $f$ to a convex envelope of $B$ or the whole ${\mathbb R}^n$ so that the uniform continuity would persist?
Can the extension be done preserving the modulus of continuity $w(r)$ when $w(r)$ is concave?