I can't speak about InDesign for the HostAdapters, but for the total re-write of all your code part... I guess you're right. If you're going to support both Flash and HTML panels, you need to develop them independently (at least for the panel itself - the actual scripting can be moved easily).
Have you checked here for the adapters? Adobe CEP Resources by Adobe-CEP
Thanks for the response.
If I may ask a follow-up question:
You're no need to rewrite tens of thousands code.
You are free to use any UI framework that suits your needs.
As I understood, Adobe supporting only Photoshop HostAdapter in Extension builder 3 for now, so in any case, in my opinion, only HTML will not give a solution to your problem.
Instead you can write your own "HostAdapter" using Adobe Illustrator CC 2014 SDK, and connect it with your (Flash/Flex)extension. (check samples with Notifiers, it will help)
According to InDesign, It's strange, because everything works smoothly for me. Can you write more detailed about that?
ps, sorry for bad English.