BEIJING — U.S. Defense Secretary Jim Mattis and Chinese leaders struck a largely positive public tone Wednesday, talking up increased military cooperation and open dialogue between the two powers despite security tensions and an impending trade war. Mattis was on his first trip to China since taking the lead at the Pentagon.