I am totally fine with your patch idea. However I have 2 comments:
could you keep the original code style? So only tab for indentation (no spaces).
could you make a fallback to embedded theme? My concern here is: what if there isn't a default theme or if if does not provide the requested icon? For this to work, rename the embedded icon so they match gnome's default theme icon's names, and have basic checks a theme loading and for each icon loading. I am ok with your cui_theme variable rename.