In this paper, we study a wireless-powered mobile edge computing (MEC) system, where the access point (AP) cooperates with an unmanned aerial vehicle (UAV). The AP broadcasts energy to the UAV, while the UAV broadcasts part of its harvested energy to the UEs and helps the UEs compute their offloaded tasks or further offload to the AP for computing. The weighted sum completed task-input bits (WSCTB) of UEs is maximized by optimizing the task allocation, the UAV's energy transmit power and trajectory, under the information-causality constraints, the energy-causality constraints, and the UAV's trajectory constraints. The formulated WSCTB maximization problem is non-convex, and a block coordinate descending algorithm is proposed to solve it iteratively. In the simulation results, the UAV's trajectory and the achieved performance are given to verify the effectiveness of the proposed algorithm in comparison with some practical baselines.